Commit f2023f2
feat: v5 rename outputs (#6689)
* chore: v5 output target modernization - rename and refactor
Major refactor to rename output targets for clarity and elevate sub-outputs
to first-class citizens, creating parity between distribution strategies.
**Naming changes:**
- `dist` → `loader-bundle` (lazy-loaded bundles + loader infrastructure)
- `dist-custom-elements` → `standalone` (individual ES modules)
- `dist-hydrate-script` → `ssr` (server-side rendering)
- `dist-collection` (sub) → `stencil-meta` (first-class, metadata output)
- `dist-types` (sub) → `types` (first-class, shared type definitions)
**Key changes:**
- Updated all constants with v5 names + deprecated v4 aliases
- Updated all type definitions (OutputTarget interfaces)
- Renamed validator files and updated their logic
- Renamed output target implementation directories
- Updated type guards with backward-compatible deprecated aliases
- Removed collectionDir/typesDir from loader-bundle config
- Updated default directories to dist/loader-bundle/, dist/standalone/, etc.
**Backward compatibility:**
- All deprecated v4 aliases maintained for migration period
- Will be removed in v6
**Documentation:**
- Added comprehensive "Output Target Modernization" section to V5_PLANNING.md
- Updated breaking changes documentation
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
* feat: add auto-generation logic for types and stencil-meta outputs
Implement auto-generation of types and stencil-meta output targets in
production builds, elevating them to first-class citizens.
**Auto-generation behavior:**
- In production builds (!config.devMode), automatically add types and
stencil-meta outputs if not explicitly configured by user
- User can override by explicitly adding these outputs to their config
- Both default to skipInDev: true for optimal dev performance
**Implementation:**
- Added autoGenerateOutputs() function in validateOutputTargets
- Created validate-types.ts for types output validation
- Default directories: dist/types/ and dist/stencil-meta/
- Maintains backward compatibility with explicit configs
This ensures parity between loader-bundle and standalone outputs,
as both now automatically get type definitions in production.
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
* chore:
* chore: remove un-required config options
* chore: tests pass
* chore: fix knip
* chore: new tests
* chore: new migration tests
* chore: removed --prod and devMode
* chore: add transpileStyle inline
* chore:
* Revert "chore: add transpileStyle inline"
This reverts commit 9cf68f4.
* chore: change collection / stencil-meta to stencil-rebundle
* chore: fixes for package.json checking / validations
* chore: rename file extensions - .cjs.js > .cjs, .esm.js > .js
* chore: update all 'collection' naming to 'rebundle'
* chore: rename dist-custom-elements related files to standalone
* chore: update testing
* chore: remove 'loader' dir. fix build tests
* chore: add esm.js to browser bundle for posterity
* chore: main work
* chore: tidy codebase
* chore: update all tests
* chore: fixup tests
* chore: better explicit global-style output options
* chore:
* chore: change all server bundle 'hydrate' refs to 'ssr'
* chore:
* chore: update default skipInDev behaviour
* chore: tidy up
* chore:
* chore:
---------
Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>1 parent 0834bed commit f2023f2
218 files changed
Lines changed: 8156 additions & 4217 deletions
File tree
- docs
- packages
- cli/src
- _test_
- migrations
- _test_
- rules
- telemetry
- _test_
- core
- src
- compiler
- build
- _test_
- bundle
- _test_
- config
- _test_
- fixtures
- outputs
- html
- output-targets
- _test_
- copy
- dist-lazy
- ssr
- standalone
- _test_
- stencil-rebundle
- service-worker/_test_
- style
- transformers
- _test_
- component-native
- rebundle
- static-to-meta
- transpile
- types
- _tests_
- declarations
- runtime
- _test_
- server
- platform
- runner
- testing
- utils
- _test_
- mock-doc/src
- test
- build
- bundle-size
- copy-task
- docs-json
- docs-readme
- custom-readme-output-overwrite/components/styleurls-component
- exports
- outputs
- type-tests
- integration
- bundler/component-library
- e2e
- ionic-app
- prerender
- runtime
- fixtures/external-base-classes
- src
- components
- attributes/reflect-to-attr
- inheritance
- extends-external-abstract
- extends-external-with-mixin
- extends-external
- styles
- css-url-paths
- style-mode-scoped
- style-mode-shadow
- special-config
- assets-global-style
- src
- components/test-asset-cmp
- assets
- external-runtime
- src/components/form-associated
- invisible-prehydration
- slot-patching
- ssr
- test
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
8 | | - | |
9 | 7 | | |
10 | 8 | | |
11 | 9 | | |
12 | 10 | | |
13 | 11 | | |
14 | 12 | | |
15 | | - | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
96 | 96 | | |
97 | 97 | | |
98 | 98 | | |
| 99 | + | |
99 | 100 | | |
100 | 101 | | |
101 | 102 | | |
| |||
170 | 171 | | |
171 | 172 | | |
172 | 173 | | |
| 174 | + | |
173 | 175 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1424 | 1424 | | |
1425 | 1425 | | |
1426 | 1426 | | |
1427 | | - | |
1428 | 1427 | | |
1429 | 1428 | | |
1430 | 1429 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
239 | 239 | | |
240 | 240 | | |
241 | 241 | | |
242 | | - | |
| 242 | + | |
243 | 243 | | |
244 | | - | |
245 | | - | |
| 244 | + | |
| 245 | + | |
246 | 246 | | |
247 | 247 | | |
248 | 248 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
14 | | - | |
| 13 | + | |
| 14 | + | |
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
54 | | - | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
55 | 60 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | | - | |
13 | | - | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
| 12 | + | |
22 | 13 | | |
23 | | - | |
| 14 | + | |
24 | 15 | | |
25 | 16 | | |
26 | 17 | | |
27 | 18 | | |
28 | 19 | | |
29 | 20 | | |
30 | 21 | | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
| 22 | + | |
| 23 | + | |
42 | 24 | | |
43 | 25 | | |
44 | 26 | | |
45 | 27 | | |
46 | | - | |
| 28 | + | |
47 | 29 | | |
48 | 30 | | |
49 | 31 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
24 | | - | |
25 | 24 | | |
26 | 25 | | |
27 | 26 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
| 10 | + | |
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
17 | | - | |
| 16 | + | |
| 17 | + | |
18 | 18 | | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
| 19 | + | |
| 20 | + | |
23 | 21 | | |
24 | 22 | | |
25 | 23 | | |
| |||
0 commit comments