@io-arc/task-webpack-typescript
TypeScript compile for webpack
Last updated 4 days ago by arcone .
ISC · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @io-arc/task-webpack-typescript 
SYNC missed versions from official npm registry.

@io-arc/task-webpack-typescript

Typescript compile for webpack.

Usage

const { js } = require('@io-arc/task-webpack-typescript')

module.exports = js

Workspace

Workspace default is src/js.

If need for change the workspace then set in config.
Config key is wsDir.js.

Build option

config to configure the build option.
Reference to @io-arc/env.

options define
minify JS_MINIFY
using file-loader USE_JS_FILE_LOADER
image hash IS_HASH_JS_FILE_LOADER
tsconfig TSCONFIG
split common filename JS_SPLIT_FILENAME
source map JS_SOURCE_MAP
eslint file ESLINT

Features

Splitting the common logic

If two or more files have common logic, extract the common logic and put it in a separate file.
For example, it's useful when you have a library like lodash or jQuery.

You can specify the file name of the common logic.

Constants

Constants configure to config.

constants config key description @io-arc/env
IS_PRODUCTION NODE_ENV=production(development) in npm scripts Whether the build mode is "production" or not IS_PRODUCTION
SITE_TITLE title Site title SITE_TITLE
URL url and siteRoot Site URL SITE_URL
SITE_AUTHOR author Site author SITE_AUTHOR
SITE_ROOT siteRoot Site root path (e.g. /) SITE_DESCRIPTION

Using library visualizer

Using webpack-visualizer-plugin.
Visualizer build run to mode is "once".

Output is <project directory>/stats.

Web Worker

Create a web worker using worker-loader.
This description to @io-arc/webpack-loader-js.

Current Tags

  • 0.0.2                                ...           latest (4 days ago)

2 Versions

  • 0.0.2                                ...           4 days ago
  • 0.0.1                                ...           4 days ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 18
Last Day 0
Last Week 18
Last Month 0
Dev Dependencies (2)
Dependents (0)
None

Copyright 2014 - 2017 © taobao.org |