Commit Graph

75 Commits

Author SHA1 Message Date
Larkin Family 6daa860f47 Updated test cases for better coverage 2016-03-12 16:23:53 -06:00
Larkin Family e6dcf5305a removed obsolete function breaking code coverage, derp 2016-02-29 16:25:05 -06:00
Sean Larkin 493f6e9b3c Was noticing undefined comments in cases, this fixes that 2016-02-29 13:48:21 -06:00
Sean Larkin c3198a9e28 Changed logic so that empty lines of
'//  \n' don't appear in UMD wrapper
2016-02-29 11:09:17 -06:00
Larkin Family ff168bbb2f realized that comments need return lines so that it doesn't break the subsequent line of logic 2016-02-27 15:01:00 -06:00
Larkin Family 86c5947904 Added tests and fixed spelling error causing initial tests to fail 2016-02-27 01:01:49 -06:00
Sean Larkin 164e33bd86 Fixed strings 2016-02-26 16:50:04 -06:00
Sean Larkin b607e97124 Adding auxiliary comments option for UMD wrapper 2016-02-26 14:25:53 -06:00
Kenny Tran eebc5ceaf6 Fix no-redeclare in code 2016-01-18 18:57:42 -08:00
Tobias Koppers ded70aef28 moves stuff from webpack-core to webpack-sources 2015-12-29 17:44:55 +01:00
Espen Volden db21a79587 Add option `umdNamedDefine` to toggle naming 2015-08-26 11:50:42 +02:00
Espen Volden dd5d8660d4 Name AMD module in UMD target if library is set
In the AMD target the AMD module gets named, but in the UMD target its
is always anonymous, even if `library` is set in the config.

This patch names the AMD module if `library` is set.

See the discussion in the referenced issue to see the background for
this change.

If its a multi part library it uses the last key in the same was as it
does with the exports hash part of the UMD declaration. Is this the best
solution?

Resolves webpack/issues/989
2015-08-24 16:47:39 +02:00
Alberto Leal 59656c9717 define call should include empty dependencies list
see: https://github.com/umdjs/umd/pull/34

> Without this, the factory may be scanned for additional dependencies matching the literal string require("module-id"), which is not correct. See https://github.com/amdjs/amdjs-api/wiki/AMD#simplified-commonjs-wrapping-.
2015-08-19 05:55:34 -04: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
Tobias Koppers 738c1d3e68 support library with CommonsChunkPlugin
fixes #622
2014-12-22 16:10:23 +01:00
Jason Anderson f371945a29 Add TemplatedPathPlugin 2014-09-11 15:31:08 +02:00
Tobias Koppers 0380796af2 Merged PR #362
code style fixes
2014-08-27 16:25:28 +02:00
Jordan Klassen 95ab7a9960 Merge remote-tracking branch 'origin/master' into optional-require-as-global
Conflicts:
	lib/UmdMainTemplatePlugin.js
2014-08-19 10:23:33 -07:00
Quentin Raynaud 3c4284f011 add a semi-colon at the end of the UMD template
Rationale: the missing semi-colon can cause bugs in some edge cases where webpack
is used to generate a library that will be concatenated in dependent project.
2014-08-03 16:05:40 +02:00
Jordan Klassen 562c446a73 add 'umd2' libraryTarget for optional amd dependancies as globals 2014-07-22 01:45:14 -07:00
Jordan Klassen 6eac904631 Optional externals in amd use globals instead of an explicit dependency
There isn't any mechanism in the amdjs spec to provide optional
dependancies (although a requirejs loader plugin could do that, it's not
standard). The best approach found was knockout's optional dependancy on
jquery, for which it doesn't use require, it only uses globals.

This solution will need to be improved for use of requirejs/amd in
commonjs environments, and could be toggled with a flag.
2014-07-17 01:42:44 -07:00
Tobias Koppers 03c87c11a4 support [name] in chunkFilename
fixes #358
2014-07-17 01:52:41 +02:00
Tobias Koppers 5104661855 optional externals
track optional modules
optional externals for UMD and root
fixes #339
2014-07-03 00:00:06 +02:00
Tobias Koppers 3247725ba3 refactored MainTemplate to plugin interface 2014-06-02 21:23:53 +02:00