Commit Graph

89 Commits

Author SHA1 Message Date
Tobias Koppers 22e7d254ee Add webpackMode optios for import()
Allow lazy, lazy-once and eager mode for import()
Fix a bug which caused context chunks to be merged when using chunk name
Allow to work in env where there is no Promise.resolve
2017-05-05 09:03:24 +02:00
SendilKumar N 75d15a9f04 refactor(ES6): WebWorkerTemplatePlugin to use const rather than var 2017-02-21 17:38:24 +08:00
SendilKumar N 30d4981209 refactor(es6): WebWorkerMainTemplatePlugin to use const rather than var 2017-02-21 17:37:25 +08:00
Tobias Koppers 4369dfa27c Merge pull request #4320 from sendilkumarn/refactor-ww
refactor(es6) Webworker module
2017-02-21 09:40:22 +01:00
SendilKumar N f2367c29d5 refactor(es6) Webworker module 2017-02-21 07:05:34 +08:00
SendilKumar N db2ff057f1 changing as per comments 2017-02-21 06:14:02 +08:00
SendilKumar N 21d9b62f33 refactor(ES6): WebWorkerChunkPluginTemplate migration
linting
2017-02-20 21:30:42 +08:00
Shubheksha Jalan 7dc617b00e refactor(ES6): upgrade WebWorkerHotUpdateChunkTemplatePlugin to ES6 2017-01-12 02:29:47 +05:30
Tobias Koppers 8e69a80847 code linting 2017-01-11 12:29:01 +01:00
Sean Larkin aa8d01bf8d refactor(eslint): Added no-unsed-vars, env specific .eslintrc's for buildin & hot (#3636)
* refactor(eslint): Added no-unsed-vars, env specific .eslintrc's for buildin & hot

* This change allows for buildin to now be part of the lint test by addition of an extra .eslintrc file which extends existing but sets es6 to false
* Turned on no-unused-vars for eslint, and then removed all warnings from turning that feature on
* Was getting notified of errors in "quote" property in eslintrc, so changed to correct value from error to 2.

* beautify

* swap invalid eslint config val
2016-12-30 09:43:49 -06:00
Tobias Koppers 54aa3cd0d6 Merge pull request #2988 from matthewtoast/master
fix: Convert webworker template runtime to be Promise-based API
2016-09-15 00:27:52 +02:00
Tobias Koppers afd11259b2 stricter linting and bug fixes 2016-09-15 00:22:10 +02:00
Matthew Trost 2e8f08f6ac Convert webworker template runtime to Promise-based API
Fixes 'cannot call method then on undefined' error when using HMR with a config
whose target is "webworker".

Probably should have happened with 2245c4acca
2016-09-12 18:40:23 -04:00
Tobias Koppers 1675a5a5ca new way to handle new ids, reuse old ids
adjusted HMR to handle id reusing
2016-07-18 00:41:26 +02:00
Tobias Koppers c838656e7f moved defaults for options.output into central place 2016-01-06 23:02:25 +01:00
Tobias Koppers ded70aef28 moves stuff from webpack-core to webpack-sources 2015-12-29 17:44:55 +01:00
Rory Hunter ebe2f371c1 Fix hot loader compatibility with Java8 Nashorn
The way that the hot loader is included in a bundle breaks in Java 8's
Nashorn engine, because of a missing semicolon. This change introduces
a placeholder value that can be correctly substituted when building
a bundle, but is otherwise inert.

Note that I don't particularly like this change, so if there's a better
fix, I'd like to hear about it.
2015-12-04 15:02:11 +00:00
Spencer Elliott c6ccf9d3a0 Add web worker HMR support 2015-11-02 22:39:24 -05:00
Tobias Koppers 431a4c791c Merge branch 'master' into webpack-2
Conflicts:
	hot/dev-server.js
	hot/only-dev-server.js
	hot/poll.js
	hot/signal.js
	lib/ChunkTemplate.js
	lib/HotModuleReplacement.runtime.js
	lib/HotModuleReplacementPlugin.js
	lib/JsonpMainTemplatePlugin.js
	lib/MainTemplate.js
	lib/NormalModule.js
	lib/Parser.js
	lib/RecordIdsPlugin.js
	lib/WebpackOptionsApply.js
	lib/dependencies/RequireEnsureDependency.js
	lib/node/OldNodeWatchFileSystem.js
	lib/optimize/OccurrenceOrderPlugin.js
	package.json
2015-07-17 09:30:37 +02:00
Tobias Koppers f7d799adb4 rebeautify without spacing after keyword 2015-07-16 00:19:23 +02:00
Avi Haiat 0a340f2b1a feat(app): Beautify all lib files 2015-07-13 01:20:09 +03:00
Avi Haiat daff7440a6 feat(app): Fix some obvious lint errors and warnings 2015-07-08 15:52:41 +03:00
Tobias Koppers aa21d14b37 fixed WebWorker template 2015-06-13 16:23:17 +02:00
Tobias Koppers cebd3b9722 added linting 2015-04-23 23:55:50 +02:00
Tobias Koppers d5dc904a15 fixed incomplete hash bug 2014-11-03 08:02:02 +01:00
Jason Anderson c84bd70b76 Fixes issue with hash length and loading external chunks
If the length option on a hash was being used for a file path template
(e.g. '[hash:8].js'), the file would be outputted with the correct name,
but the reference inside require.ensure would not work, because the length
truncation would operate on more than just the hash, and would truncate
some of the characters added to pad the hash value.

Fix is to implement the `hashWithLength` function where this is a problem.
This doesn't feel like a proper solution, as it adds some redundancies
in a few places, but it's only in the chunk loading blocks that this matters,
so it's small in scope.
2014-10-28 11:51:18 +01:00
Jason Anderson f371945a29 Add TemplatedPathPlugin 2014-09-11 15:31:08 +02:00
Kurt Harriger bdae82a290 Replace ad-hoc identifier cleansing with helper function
Generalized identifier cleansing to replace invalid (and unicode)
characters with underscores to ensure a valid function name.

Applied function in other places functions were generated based on
libarary name.
2014-08-04 08:25:33 -06:00
Tobias Koppers 03c87c11a4 support [name] in chunkFilename
fixes #358
2014-07-17 01:52:41 +02:00
Tobias Koppers a0394a061b refactored ChunkTemplate with plugin interface 2014-06-02 23:40:50 +02:00
Tobias Koppers 3247725ba3 refactored MainTemplate to plugin interface 2014-06-02 21:23:53 +02:00
Tobias Koppers bea08dc1a2 added node-webkit target (experimental)
added option to provide no target
added defaults for node-webkit
allow browsertests to run in node-webkit
2014-04-09 09:12:04 +02:00
Tobias Koppers 8851427ea2 use chunk ids in entry chunks too
this fixes a unnecessary download in mutli-entry compilations
2013-12-11 08:41:43 +01:00
Tobias Koppers 327a990070 fixed bugs 2013-06-19 11:53:03 +02:00
Tobias Koppers c30f16f439 added experimental deduplication support #47 2013-06-12 16:16:06 +02:00
Tobias Koppers 0de7c73ad8 SourceMap support 2013-03-26 16:54:41 +01:00
Tobias Koppers 9fe83b3dc8 improved chunk loading
now a chunk is not loaded if all included modules are already loaded (by other chunks)
2013-02-24 02:05:55 +01:00
Tobias Koppers b0a7d774a0 removed error handling, it's handled while compiling 2013-02-13 17:37:21 +01:00
Tobias Koppers 3dc62749a2 moved webworker template, added node.js template #57 2013-02-13 17:00:07 +01:00