Tobias Koppers
c41eb368f2
Merge pull request #15182 from webpack/bugfix/lib-ident-includes-layer
...
Module.libIdent is scoped by the module layer if there is one
2022-01-18 09:59:01 +01:00
Tobias Koppers
6b83f85141
Module.libIdent is scoped by the module layer if there is one
2022-01-14 12:05:28 +01:00
Asriel Yu
136b723023
fix callback err type should include null
2021-12-24 20:27:31 +08:00
Ben Harris
bbe72b3eae
Added testing for new singleton logic (and caught a typo in the process!)
2021-12-02 11:44:23 -05:00
Ben Harris
92e373028d
Proposed fix to module federation to stop ignoring the singleton flag when requiredVersion is false
2021-12-01 21:07:29 -05:00
Tobias Koppers
6fbcd415d4
improve runtime code
2021-11-25 09:57:48 +01:00
tanhauhau
0e2337dfb7
feat: show which singleton loaded version
2021-11-21 10:59:30 +08:00
Aleen
ab34ffb2ae
Revert to use ['catch'] directly
2021-11-02 12:52:00 +08:00
Aleen
4c50786098
use propertyAccess to generate .catch code
2021-11-02 12:51:59 +08:00
Tobias Koppers
e21b1d46fe
precompile schemas for improved startup performance
2021-04-16 16:02:58 +02:00
Tobias Koppers
d808d04d26
attach the chunk graph to RuntimeModules
2021-04-14 12:26:35 +02:00
Tobias Koppers
7f4ce2cf1a
add expressionFunction helper to choose shortest variant when return value is not relevant
2021-03-15 15:40:30 +01:00
Seth Benjamin
9fa45137d8
fix: use runtime globals in shared plugin
...
- Fixes a bug that caused HMR to fail when using Module Federation (__webpack_modules__ is not defined).
2021-03-07 16:03:05 -08:00
Tobias Koppers
495cabb94d
improve TLA consistency
2021-01-29 13:51:32 +01:00
Tobias Koppers
a08eca78ff
Merge pull request #12132 from jakenorthey/feature/prioritize-eager-shared-modules
2021-01-18 17:00:21 +01:00
Tobias Koppers
58d459bff1
accept truthy/falsy values for eager
...
save 2 chars for each provided shared module
prettify test cases
2021-01-14 14:24:34 +01:00
Tobias Koppers
48571c663f
add selective runtime requirements from startup logic which doesn't prevent inlining modules
...
avoid using startup function for grab data from preexecuted chunks
2020-12-11 14:36:48 +01:00
Jake Northey
8f7fac5fa2
fix: fix syntax error and add tests for comparing eager to eager modules and non-eager to non-eager modules
2020-12-08 18:54:40 -05:00
Jake
60183bd220
fix: handle eager === activeVersion.eager === true
...
Co-authored-by: Tobias Koppers <tobias.koppers@googlemail.com>
2020-12-07 08:30:51 -05:00
Jake Northey
3fe999a621
fix: remove unnecessary default parameter value
2020-12-05 14:59:37 -05:00
Jake Northey
19d6f52ca7
check if existing dependency is eagerly loaded
2020-12-03 12:24:14 -05:00
Jake Northey
1d9b77c060
prioritize eager shared module dependencies in dependency registration
2020-12-03 12:07:14 -05:00
evilebottnawi
8c19efb7fd
chore(deps): update `schema-utils`
2020-10-05 21:58:54 +03:00
Tobias Koppers
a8542d3317
fix circular references between containers and modules in containers
2020-09-17 10:44:52 +02:00
Tobias Koppers
2d842c0508
pass on shareScope in SharePlugin
2020-08-03 14:32:42 +02:00
Tobias Koppers
e16bdfda6c
refactor used exports analysis, hashing, code generation, optimizations
...
to keep track of runtimes, used exports depending on runtime
modules can have different hashes and generated code depending on runtime
chunks are only considered as equal for MergeDuplicateChunks and SplitChunks when exports used in contained modules are equal
added `optimization.usedExports: "global"` to opt-out from used exports analysis per runtime
added `splitChunks.usedExports` and `splitChunks.cacheGroups[x].usedExports` to enable/disable used exports comparing for modules
`splitChunks.usedExports` defaults to `true` in production
2020-07-27 22:40:44 +02:00
Tobias Koppers
b0cc32cb17
providing module do not override already loaded modules
...
fixes a bug where dynamic loaded containers override shared modules
2020-07-09 10:40:36 +02:00
Tobias Koppers
2689d026b1
refactor semver logic to be internal
...
share scope uses string version instead of parsed one
2020-07-02 16:09:57 +02:00
Tobias Koppers
2a0620a7f1
improve semver range detection
2020-07-02 16:09:50 +02:00
Tobias Koppers
a9993bbabf
improve semver range detection
2020-07-02 16:09:46 +02:00
Tobias Koppers
3fcd5f9bc5
add full Semantic Versioning for Shared Modules
...
change storage format in the share scope
choose shared module deterministic from the same origin
remove array syntax from version and requiredVersion in schema
2020-07-02 16:09:39 +02:00
Tobias Koppers
23f922bed3
make bundles with Module Federation more stable
2020-07-02 15:28:17 +02:00
Tobias Koppers
79f3694034
fix casing in ProvideSharedPlugin
2020-06-24 23:06:37 +02:00
Tobias Koppers
b30b9681fa
opt-out from unsafe caching when providing shared module as side-effect
2020-06-24 23:06:36 +02:00
Tobias Koppers
630ebfdf47
rename module federation classes for be more specific
2020-06-18 15:11:29 +02:00
Tobias Koppers
2abcfc0058
set dependency categories for all dependencies
2020-06-17 23:04:37 +02:00
Ivan Kopeykin
8174145782
upgrade enhanced-resolve
2020-06-17 14:22:37 +03:00
Ivan Kopeykin
9061a5ca94
add RESOLVE_OPTIONS to resolveMatchedConfigs
2020-06-16 21:20:46 +03:00
Ivan Kopeykin
198e51a485
Merge branch 'master' into exports-field
...
# Conflicts:
# lib/dependencies/ImportDependency.js
# lib/sharing/ConsumeSharedPlugin.js
# lib/sharing/ProvideSharedPlugin.js
# types.d.ts
2020-06-16 21:16:41 +03:00
Ivan Kopeykin
3f8def8185
fix discussions
...
- add module condition
- rename EnhancedResolveOptions
- fix applyByDependency util function
- use EMPTY_RESOLVE_OPTIONS when resolveOptions are undefined
2020-06-16 21:02:31 +03:00
Tobias Koppers
590af1edfe
improve readable names
...
update example
add optionalDependencies to automatic requiredVersion sources
2020-06-15 22:45:36 +02:00
Tobias Koppers
1864cf59ad
fix resolving of direct fallback requests
...
fix persistent caching test case
2020-06-15 20:12:38 +02:00
Tobias Koppers
92a3079f29
fix typing errors
2020-06-15 20:12:36 +02:00
Tobias Koppers
ad56d8abb1
improve handling of relative/absolute requests in the ProvideSharedPlugin
2020-06-15 16:20:34 +02:00
Tobias Koppers
d1828d4582
allow ProvideSharedPlugin to handle relative requests
2020-06-13 15:17:28 +02:00
Tobias Koppers
1c42f71250
allow to provide and consume multiple versions of shared modules
2020-06-13 14:45:37 +02:00
Tobias Koppers
42e14d6a42
provide shared based on used modules and used version
2020-06-10 16:30:08 +02:00
Ivan Kopeykin
d2a08e3cc8
rework how byDependency applied
...
remove dependencyType parameter for resolver factory
add dependencyType option in enhanced resolve options
2020-06-09 01:32:24 +03:00
Tobias Koppers
3df380e2d7
add script external
...
change defaults of ModuleFederationPlugin to var library and script remoteType
allow using empty entry in config
2020-06-04 03:18:07 +02:00
Ivan Kopeykin
d7dd4ececb
use resolverFactory.get with dep category option
2020-06-01 15:16:14 +03:00