@quilted/rollup 0.1.19 → 0.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (129) hide show
  1. package/CHANGELOG.md +27 -0
  2. package/build/esm/app.mjs +450 -222
  3. package/build/esm/constants.mjs +5 -5
  4. package/build/esm/features/assets.mjs +93 -81
  5. package/build/esm/features/async.mjs +186 -0
  6. package/build/esm/features/css.mjs +26 -39
  7. package/build/esm/features/env.mjs +47 -44
  8. package/build/esm/features/esnext.mjs +57 -0
  9. package/build/esm/features/graphql/transform.mjs +60 -56
  10. package/build/esm/features/graphql.mjs +65 -47
  11. package/build/esm/features/request-router.mjs +6 -4
  12. package/build/esm/features/source-code.mjs +54 -28
  13. package/build/esm/features/system-js.mjs +29 -20
  14. package/build/esm/features/typescript.mjs +13 -10
  15. package/build/esm/features/workers.mjs +173 -0
  16. package/build/esm/index.mjs +3 -2
  17. package/build/esm/module.mjs +69 -62
  18. package/build/esm/package.mjs +275 -84
  19. package/build/esm/server.mjs +118 -0
  20. package/build/esm/shared/browserslist.mjs +141 -16
  21. package/build/esm/shared/magic-module.mjs +9 -7
  22. package/build/esm/shared/package-json.mjs +7 -1
  23. package/build/esm/shared/path.mjs +7 -0
  24. package/build/esm/shared/rollup.mjs +89 -25
  25. package/build/esm/shared/strings.mjs +7 -6
  26. package/build/tsconfig.tsbuildinfo +1 -1
  27. package/build/typescript/app.d.ts +132 -29
  28. package/build/typescript/app.d.ts.map +1 -1
  29. package/build/typescript/features/assets.d.ts +1 -2
  30. package/build/typescript/features/assets.d.ts.map +1 -1
  31. package/build/typescript/features/async.d.ts +10 -0
  32. package/build/typescript/features/async.d.ts.map +1 -0
  33. package/build/typescript/features/css.d.ts +2 -1
  34. package/build/typescript/features/css.d.ts.map +1 -1
  35. package/build/typescript/features/env.d.ts +1 -0
  36. package/build/typescript/features/env.d.ts.map +1 -1
  37. package/build/typescript/features/esnext.d.ts +9 -0
  38. package/build/typescript/features/esnext.d.ts.map +1 -0
  39. package/build/typescript/features/graphql.d.ts +2 -2
  40. package/build/typescript/features/graphql.d.ts.map +1 -1
  41. package/build/typescript/features/source-code.d.ts +9 -3
  42. package/build/typescript/features/source-code.d.ts.map +1 -1
  43. package/build/typescript/features/system-js.d.ts +4 -1
  44. package/build/typescript/features/system-js.d.ts.map +1 -1
  45. package/build/typescript/features/workers.d.ts +52 -0
  46. package/build/typescript/features/workers.d.ts.map +1 -0
  47. package/build/typescript/index.d.ts +3 -2
  48. package/build/typescript/index.d.ts.map +1 -1
  49. package/build/typescript/module.d.ts +24 -6
  50. package/build/typescript/module.d.ts.map +1 -1
  51. package/build/typescript/package.d.ts +196 -4
  52. package/build/typescript/package.d.ts.map +1 -1
  53. package/build/typescript/server.d.ts +98 -0
  54. package/build/typescript/server.d.ts.map +1 -0
  55. package/build/typescript/shared/browserslist.d.ts +20 -3
  56. package/build/typescript/shared/browserslist.d.ts.map +1 -1
  57. package/build/typescript/shared/path.d.ts +2 -0
  58. package/build/typescript/shared/path.d.ts.map +1 -0
  59. package/build/typescript/shared/rollup.d.ts +27 -1
  60. package/build/typescript/shared/rollup.d.ts.map +1 -1
  61. package/configuration/rollup.config.js +40 -0
  62. package/package.json +62 -9
  63. package/source/app.ts +475 -99
  64. package/source/features/assets.ts +5 -7
  65. package/source/features/async.ts +249 -0
  66. package/source/features/css.ts +4 -2
  67. package/source/features/env.ts +6 -0
  68. package/source/features/esnext.ts +70 -0
  69. package/source/features/graphql.ts +4 -2
  70. package/source/features/source-code.ts +27 -9
  71. package/source/features/system-js.ts +25 -2
  72. package/source/features/workers.ts +292 -0
  73. package/source/index.ts +4 -0
  74. package/source/module.ts +45 -19
  75. package/source/package.ts +394 -36
  76. package/source/server.ts +245 -0
  77. package/source/shared/browserslist.ts +208 -18
  78. package/source/shared/path.ts +5 -0
  79. package/source/shared/rollup.ts +102 -4
  80. package/tsconfig.json +6 -2
  81. package/build/cjs/app.cjs +0 -441
  82. package/build/cjs/constants.cjs +0 -13
  83. package/build/cjs/features/assets.cjs +0 -240
  84. package/build/cjs/features/css.cjs +0 -71
  85. package/build/cjs/features/env.cjs +0 -135
  86. package/build/cjs/features/graphql/transform.cjs +0 -186
  87. package/build/cjs/features/graphql.cjs +0 -86
  88. package/build/cjs/features/request-router.cjs +0 -31
  89. package/build/cjs/features/source-code.cjs +0 -54
  90. package/build/cjs/features/system-js.cjs +0 -36
  91. package/build/cjs/features/typescript.cjs +0 -56
  92. package/build/cjs/index.cjs +0 -13
  93. package/build/cjs/module.cjs +0 -121
  94. package/build/cjs/package.cjs +0 -170
  95. package/build/cjs/shared/browserslist.cjs +0 -25
  96. package/build/cjs/shared/magic-module.cjs +0 -32
  97. package/build/cjs/shared/package-json.cjs +0 -31
  98. package/build/cjs/shared/rollup.cjs +0 -72
  99. package/build/cjs/shared/strings.cjs +0 -16
  100. package/build/esnext/app.esnext +0 -414
  101. package/build/esnext/constants.esnext +0 -7
  102. package/build/esnext/features/assets.esnext +0 -215
  103. package/build/esnext/features/css.esnext +0 -69
  104. package/build/esnext/features/env.esnext +0 -112
  105. package/build/esnext/features/graphql/transform.esnext +0 -181
  106. package/build/esnext/features/graphql.esnext +0 -84
  107. package/build/esnext/features/request-router.esnext +0 -29
  108. package/build/esnext/features/source-code.esnext +0 -51
  109. package/build/esnext/features/system-js.esnext +0 -33
  110. package/build/esnext/features/typescript.esnext +0 -34
  111. package/build/esnext/index.esnext +0 -3
  112. package/build/esnext/module.esnext +0 -100
  113. package/build/esnext/package.esnext +0 -148
  114. package/build/esnext/shared/browserslist.esnext +0 -23
  115. package/build/esnext/shared/magic-module.esnext +0 -30
  116. package/build/esnext/shared/package-json.esnext +0 -10
  117. package/build/esnext/shared/rollup.esnext +0 -49
  118. package/build/esnext/shared/strings.esnext +0 -14
  119. package/build/typescript/env.d.ts +0 -55
  120. package/build/typescript/env.d.ts.map +0 -1
  121. package/build/typescript/graphql/transform.d.ts +0 -17
  122. package/build/typescript/graphql/transform.d.ts.map +0 -1
  123. package/build/typescript/graphql.d.ts +0 -6
  124. package/build/typescript/graphql.d.ts.map +0 -1
  125. package/build/typescript/request-router.d.ts +0 -15
  126. package/build/typescript/request-router.d.ts.map +0 -1
  127. package/build/typescript/shared/source-code.d.ts +0 -5
  128. package/build/typescript/shared/source-code.d.ts.map +0 -1
  129. package/quilt.project.ts +0 -5
@@ -1,7 +1,8 @@
1
- import type { Plugin, GetManualChunk } from 'rollup';
2
- import type { MagicModuleEnvOptions } from './features/env.ts';
3
- import { type BrowserTargetSelection } from './shared/browserslist.ts';
4
- export interface AppOptions {
1
+ import type { Plugin, RollupOptions, GetManualChunk } from 'rollup';
2
+ import { type MagicModuleEnvOptions } from './features/env.ts';
3
+ import { type RollupNodePluginOptions } from './shared/rollup.ts';
4
+ import { type BrowserGroupTargetSelection } from './shared/browserslist.ts';
5
+ export interface AppBaseOptions {
5
6
  /**
6
7
  * The root directory containing the source code for your application.
7
8
  */
@@ -28,12 +29,27 @@ export interface AppOptions {
28
29
  graphql?: boolean;
29
30
  /**
30
31
  * Customizes the behavior of environment variables for your application. You
31
- * can further customize the environment variables provided during server-side
32
- * rendering by passing `server.env`.
32
+ * can further customize the environment variables provided to browser assets
33
+ * by passing the `browser.env`, and those passed during server-side rendering
34
+ * by passing `server.env`.
33
35
  */
34
- env?: MagicModuleEnvOptions;
36
+ env?: MagicModuleEnvOptions | MagicModuleEnvOptions['mode'];
35
37
  }
36
- export interface AppBrowserOptions extends AppOptions {
38
+ export interface AppOptions extends AppBaseOptions {
39
+ /**
40
+ * Customizes the browser build of your application.
41
+ */
42
+ browser?: Omit<AppBrowserOptions, keyof AppBaseOptions> & Pick<AppBrowserOptions, 'env'>;
43
+ /**
44
+ * Customizes the assets created for your application.
45
+ */
46
+ assets?: AppBrowserOptions['assets'];
47
+ /**
48
+ * Customizes the server build of your application.
49
+ */
50
+ server?: Omit<AppServerOptions, keyof AppBaseOptions> & Pick<AppServerOptions, 'env'>;
51
+ }
52
+ export interface AppBrowserOptions extends AppBaseOptions {
37
53
  /**
38
54
  * The entry module for this browser. This should be an absolute path, or relative
39
55
  * path from the root directory containing your project. This entry should be the
@@ -69,50 +85,119 @@ export interface AppBrowserModuleOptions {
69
85
  }
70
86
  export interface AppBrowserAssetsOptions {
71
87
  /**
72
- * Whether to minify assets created by Quilt.
88
+ * Whether to minify assets created for you application.
73
89
  *
74
90
  * @default true
75
91
  */
76
92
  minify?: boolean;
77
93
  baseURL?: string;
78
- targets?: BrowserTargetSelection;
94
+ targets?: BrowserGroupTargetSelection;
79
95
  priority?: number;
96
+ clean?: boolean;
97
+ /**
98
+ * Controls how assets like images are inlined into your bundles JavaScript.
99
+ */
100
+ inline?: boolean | {
101
+ /**
102
+ * The maximum size in bytes that an asset should be in order to
103
+ * be inlined into the bundle. Defaults to `4096`.
104
+ */
105
+ limit?: number;
106
+ };
80
107
  }
108
+ export interface AppServerOptions extends AppBaseOptions {
109
+ /**
110
+ * The entry module for this app’s server. By default, this module must export
111
+ * a `RequestRouter` object as its default export, which will be wrapped in
112
+ * the specific server runtime you configure. If you set the format to `'custom'`,
113
+ * this entry can be any content — it will be bundled as-is.
114
+ *
115
+ * If not provided, this will default to a file named `server`, `service`,
116
+ * or `backend` in your app’s root directory.
117
+ */
118
+ entry?: string;
119
+ /**
120
+ * Whether this server code uses the `request-router` library to
121
+ * define itself in a generic way, which can be adapted to a variety
122
+ * of environments. By default, this is `'request-router'`, and when `'request-router'`,
123
+ * the `entry` you specified must export an `RequestRouter` object as
124
+ * its default export. When set to `false`, the app server will be built
125
+ * as a basic server-side JavaScript project, without the special
126
+ * `request-router` adaptor.
127
+ *
128
+ * @default 'request-router'
129
+ */
130
+ format?: 'request-router' | 'custom';
131
+ /**
132
+ * Customizes the assets created for your application.
133
+ */
134
+ assets?: Pick<AppBrowserAssetsOptions, 'baseURL' | 'inline'>;
135
+ /**
136
+ * Customizes the output files created for your server.
137
+ */
138
+ output?: AppServerOutputOptions;
139
+ }
140
+ export interface AppServerOutputOptions extends Pick<RollupNodePluginOptions, 'bundle'> {
141
+ /**
142
+ * Whether to minify assets created for this server.
143
+ *
144
+ * @default false
145
+ */
146
+ minify?: boolean;
147
+ /**
148
+ * Whether to add a hash to the output files for your server. You can set
149
+ * this to `true`, which includes a hash for all files, `false`, which never
150
+ * includes a hash, or `'async-only'`, which only includes a hash for files
151
+ * that are loaded asynchronously (that is, your entry file will not have a
152
+ * hash, but any files it loads will).
153
+ *
154
+ * @default 'async-only'
155
+ */
156
+ hash?: boolean | 'async-only';
157
+ /**
158
+ * What module format to use for the server output.
159
+ *
160
+ * @default 'esmodules'
161
+ */
162
+ format?: 'esmodules' | 'esm' | 'es' | 'commonjs' | 'cjs';
163
+ }
164
+ export declare function quiltApp({ root: rootPath, app, env, graphql, assets, browser: browserOptions, server: serverOptions, }?: AppOptions): Promise<RollupOptions[]>;
81
165
  export declare function quiltAppBrowser({ root: rootPath, app, entry, env, assets, module, graphql, }?: AppBrowserOptions): Promise<{
82
- input: string;
166
+ input: string | {
167
+ browser: string;
168
+ };
83
169
  plugins: Plugin<any>[];
84
170
  onwarn(warning: import("rollup").RollupLog, defaultWarn: import("rollup").LoggingFunction): void;
85
171
  output: {
86
- format: "esm";
172
+ format: "esm" | "systemjs";
87
173
  dir: string;
88
174
  entryFileNames: string;
89
175
  assetFileNames: string;
90
176
  chunkFileNames: string;
91
177
  manualChunks: GetManualChunk;
178
+ generatedCode: {
179
+ preset: "es2015";
180
+ arrowFunctions: boolean;
181
+ constBindings: boolean;
182
+ objectShorthand: boolean;
183
+ reservedNamesAsProps: boolean;
184
+ symbols: boolean;
185
+ };
92
186
  };
93
187
  }>;
94
- export interface AppServerOptions extends AppOptions {
95
- /**
96
- * The entry module for the server of this app. This module must export a
97
- * `RequestRouter` object as its default export, which will be wrapped in
98
- * the specific server runtime you configure.
99
- */
100
- entry?: string;
101
- /**
102
- * Whether to minify the JavaScript outputs for your server.
103
- *
104
- * @default false
105
- */
106
- minify?: boolean;
107
- }
108
- export declare function quiltAppServer({ app, env, entry, graphql, minify, }?: AppServerOptions): Promise<{
109
- input: string;
188
+ export declare function quiltAppServer({ root: rootPath, app, env, entry, format, graphql, assets, output, }?: AppServerOptions): Promise<{
189
+ input: string | {
190
+ server: string;
191
+ };
110
192
  plugins: Plugin<any>[];
111
193
  onwarn(warning: import("rollup").RollupLog, defaultWarn: import("rollup").LoggingFunction): void;
112
194
  output: {
113
- format: "esm";
195
+ format: "cjs" | "esm";
114
196
  dir: string;
115
197
  entryFileNames: string;
198
+ chunkFileNames: string;
199
+ assetFileNames: string;
200
+ generatedCode: "es2015";
116
201
  };
117
202
  }>;
118
203
  export declare function magicModuleAppComponent({ entry }: {
@@ -150,6 +235,24 @@ export declare function magicModuleAppBrowserEntry({ hydrate, selector, }?: AppB
150
235
  moduleSideEffects: "no-treeshake" | undefined;
151
236
  } | null>) | undefined;
152
237
  };
238
+ export declare function magicModuleAppServerEntry({ host, port, assets, format, }?: {
239
+ host?: string;
240
+ port?: number;
241
+ assets?: boolean | {
242
+ baseURL: string;
243
+ };
244
+ format?: 'module' | 'commonjs';
245
+ }): {
246
+ name: string;
247
+ resolveId(this: import("rollup").PluginContext, id: string): {
248
+ id: string;
249
+ moduleSideEffects: "no-treeshake" | undefined;
250
+ } | null;
251
+ load: ((this: import("rollup").PluginContext, source: string) => Promise<{
252
+ code: string;
253
+ moduleSideEffects: "no-treeshake" | undefined;
254
+ } | null>) | undefined;
255
+ };
153
256
  export declare function magicModuleAppAssetManifests(): {
154
257
  name: string;
155
258
  resolveId(this: import("rollup").PluginContext, id: string): {
@@ -1 +1 @@
1
- {"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../../source/app.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAC,MAAM,EAAiB,cAAc,EAAC,MAAM,QAAQ,CAAC;AASlE,OAAO,KAAK,EAAC,qBAAqB,EAAC,MAAM,mBAAmB,CAAC;AAK7D,OAAO,EAEL,KAAK,sBAAsB,EAC5B,MAAM,0BAA0B,CAA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QAAQ,GAAG,UAAU,CAAC;CAC3B;;;;;;;;;;EAyDL;AAED,wBAAgB,4BAA4B;;;;;;;;;;EAqE3C"}
@@ -1,10 +1,9 @@
1
1
  import type { Plugin, PluginContext } from 'rollup';
2
2
  export interface AssetManifestOptions {
3
- id?: string;
4
3
  file: string;
5
4
  baseURL: string;
6
5
  priority?: number;
7
- cacheKey?: Record<string, any>;
6
+ cacheKey?: URLSearchParams;
8
7
  }
9
8
  export declare function assetManifest(manifestOptions: AssetManifestOptions): Plugin;
10
9
  export declare function rawAssets(): Plugin;
@@ -1 +1 @@
1
- {"version":3,"file":"assets.d.ts","sourceRoot":"","sources":["../../../source/features/assets.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAIV,MAAM,EACN,aAAa,EACd,MAAM,QAAQ,CAAC;AAQhB,MAAM,WAAW,oBAAoB;IACnC,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;CAChC;AAED,wBAAgB,aAAa,CAAC,eAAe,EAAE,oBAAoB,GAAG,MAAM,CAO3E;AAiKD,wBAAgB,SAAS,IAAI,MAAM,CAmBlC;AAED,wBAAgB,YAAY,CAAC,EAC3B,IAAW,EACX,OAAa,EACb,UAA4C,EAC5C,WAAkC,EAClC,aAAsC,GACvC,GAAE;IACD,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAC/B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,aAAa,CAAC,EAAE,MAAM,CAAC;CACnB;;;EA+DL"}
1
+ {"version":3,"file":"assets.d.ts","sourceRoot":"","sources":["../../../source/features/assets.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAIV,MAAM,EACN,aAAa,EACd,MAAM,QAAQ,CAAC;AAQhB,MAAM,WAAW,oBAAoB;IACnC,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,eAAe,CAAC;CAC5B;AAED,wBAAgB,aAAa,CAAC,eAAe,EAAE,oBAAoB,GAAG,MAAM,CAO3E;AAgKD,wBAAgB,SAAS,IAAI,MAAM,CAmBlC;AAED,wBAAgB,YAAY,CAAC,EAC3B,IAAW,EACX,OAAa,EACb,UAA4C,EAC5C,WAAkC,EAClC,aAAsC,GACvC,GAAE;IACD,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAC/B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,aAAa,CAAC,EAAE,MAAM,CAAC;CACnB;;;EA+DL"}
@@ -0,0 +1,10 @@
1
+ import type { Plugin } from 'rollup';
2
+ export interface Options {
3
+ preload?: boolean;
4
+ baseURL?: string;
5
+ moduleID?(details: {
6
+ imported: string;
7
+ }): string;
8
+ }
9
+ export declare function asyncModules({ preload, baseURL, moduleID: getModuleID, }?: Options): Plugin;
10
+ //# sourceMappingURL=async.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"async.d.ts","sourceRoot":"","sources":["../../../source/features/async.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAC,MAAM,EAA4B,MAAM,QAAQ,CAAC;AAO9D,MAAM,WAAW,OAAO;IACtB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,CAAC,OAAO,EAAE;QAAC,QAAQ,EAAE,MAAM,CAAA;KAAC,GAAG,MAAM,CAAC;CAChD;AAED,wBAAgB,YAAY,CAAC,EAC3B,OAAc,EACd,OAAoB,EACpB,QAAQ,EAAE,WAA6B,GACxC,GAAE,OAAY,GAAG,MAAM,CA2FvB"}
@@ -1,8 +1,9 @@
1
1
  export interface Options {
2
2
  minify?: boolean;
3
3
  emit?: boolean;
4
+ targets?: string[];
4
5
  }
5
- export declare function css({ minify, emit }: Options): {
6
+ export declare function css({ minify, emit, targets }: Options): {
6
7
  name: string;
7
8
  transform(this: import("rollup").TransformPluginContext, code: string, id: string): Promise<{
8
9
  code: string;
@@ -1 +1 @@
1
- {"version":3,"file":"css.d.ts","sourceRoot":"","sources":["../../../source/features/css.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,OAAO;IACtB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,IAAI,CAAC,EAAE,OAAO,CAAC;CAChB;AAKD,wBAAgB,GAAG,CAAC,EAAC,MAAa,EAAE,IAAW,EAAC,EAAE,OAAO;;;;;;;;;;EAgFxD"}
1
+ {"version":3,"file":"css.d.ts","sourceRoot":"","sources":["../../../source/features/css.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,OAAO;IACtB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;CACpB;AAKD,wBAAgB,GAAG,CAAC,EAAC,MAAa,EAAE,IAAW,EAAE,OAAO,EAAC,EAAE,OAAO;;;;;;;;;;EAiFjE"}
@@ -41,6 +41,7 @@ export interface MagicModuleEnvOptions {
41
41
  files?: string[];
42
42
  };
43
43
  }
44
+ export declare function resolveEnvOption(option?: MagicModuleEnvOptions['mode'] | MagicModuleEnvOptions): MagicModuleEnvOptions;
44
45
  export declare function magicModuleEnv({ mode, dotenv, inline, runtime, }?: MagicModuleEnvOptions): {
45
46
  name: string;
46
47
  resolveId(this: PluginContext, id: string): {
@@ -1 +1 @@
1
- {"version":3,"file":"env.d.ts","sourceRoot":"","sources":["../../../source/features/env.ts"],"names":[],"mappings":"A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;IAEjB;;;;;;;;;;;OAWG;IACH,MAAM,CAAC,EACH,KAAK,GACL;QAAC,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;QAAC,KAAK,CAAC,EAAE,KAAK,CAAA;KAAC,GACjC;QAAC,KAAK,CAAC,EAAE,KAAK,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,EAAE,CAAA;KAAC,CAAC;CACvC;AAED,wBAAgB,gBAAgB,CAC9B,MAAM,CAAC,EAAE,qBAAqB,CAAC,MAAM,CAAC,GAAG,qBAAqB,yBAG/D;AAED,wBAAgB,cAAc,CAAC,EAC7B,IAAI,EACJ,MAAwC,EACxC,MAAW,EACX,OAAc,GACf,GAAE,qBAA0B;;;;;;;;;4BAjD3B;;OAEG;EAyFJ"}
@@ -0,0 +1,9 @@
1
+ import { type RollupBabelInputPluginOptions } from '@rollup/plugin-babel';
2
+ export declare function esnext({ mode, targets, babel: useBabel, }: {
3
+ mode?: 'development' | 'production';
4
+ targets?: readonly string[];
5
+ babel?: boolean | {
6
+ options?(options: RollupBabelInputPluginOptions): RollupBabelInputPluginOptions | void;
7
+ };
8
+ }): import("rollup").Plugin<any>;
9
+ //# sourceMappingURL=esnext.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"esnext.d.ts","sourceRoot":"","sources":["../../../source/features/esnext.ts"],"names":[],"mappings":"AAEA,OAAc,EAAC,KAAK,6BAA6B,EAAC,MAAM,sBAAsB,CAAC;AAK/E,wBAAgB,MAAM,CAAC,EACrB,IAAI,EACJ,OAAO,EACP,KAAK,EAAE,QAAe,GACvB,EAAE;IACD,IAAI,CAAC,EAAE,aAAa,GAAG,YAAY,CAAC;IACpC,OAAO,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAC5B,KAAK,CAAC,EACF,OAAO,GACP;QACE,OAAO,CAAC,CACN,OAAO,EAAE,6BAA6B,GACrC,6BAA6B,GAAG,IAAI,CAAC;KACzC,CAAC;CACP,gCAgDA"}
@@ -1,6 +1,6 @@
1
1
  import type { Plugin } from 'rollup';
2
- export interface Options {
2
+ export interface GraphQLOptions {
3
3
  manifest?: string | boolean;
4
4
  }
5
- export declare function graphql({ manifest }?: Options): Plugin;
5
+ export declare function graphql({ manifest }?: GraphQLOptions): Plugin;
6
6
  //# sourceMappingURL=graphql.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"graphql.d.ts","sourceRoot":"","sources":["../../../source/features/graphql.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAC,MAAM,EAAyB,MAAM,QAAQ,CAAC;AAQ3D,MAAM,WAAW,OAAO;IACtB,QAAQ,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;CAC7B;AAED,wBAAgB,OAAO,CAAC,EAAC,QAAQ,EAAC,GAAE,OAAY,GAAG,MAAM,CAiExD"}
1
+ {"version":3,"file":"graphql.d.ts","sourceRoot":"","sources":["../../../source/features/graphql.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAC,MAAM,EAAyB,MAAM,QAAQ,CAAC;AAQ3D,MAAM,WAAW,cAAc;IAC7B,QAAQ,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;CAC7B;AAED,wBAAgB,OAAO,CAAC,EAAC,QAAQ,EAAC,GAAE,cAAmB,GAAG,MAAM,CAmE/D"}
@@ -1,6 +1,12 @@
1
- export declare function sourceCode({ mode, targets, babel: useBabel, }: {
1
+ import { type RollupBabelInputPluginOptions } from '@rollup/plugin-babel';
2
+ import type { Options as PresetEnvOptions } from '@babel/preset-env';
3
+ export declare function sourceCode({ mode, targets, react, babel: useBabel, }: {
2
4
  mode?: 'development' | 'production';
3
- targets?: string[];
4
- babel?: boolean;
5
+ react?: boolean | 'react' | 'preact';
6
+ targets?: readonly string[];
7
+ babel?: boolean | {
8
+ useBuiltIns?: PresetEnvOptions['useBuiltIns'];
9
+ options?(options: RollupBabelInputPluginOptions): RollupBabelInputPluginOptions | void;
10
+ };
5
11
  }): import("rollup").Plugin<any>;
6
12
  //# sourceMappingURL=source-code.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"source-code.d.ts","sourceRoot":"","sources":["../../../source/features/source-code.ts"],"names":[],"mappings":"AAOA,wBAAgB,UAAU,CAAC,EACzB,IAAI,EACJ,OAAO,EACP,KAAK,EAAE,QAAe,GACvB,EAAE;IACD,IAAI,CAAC,EAAE,aAAa,GAAG,YAAY,CAAC;IACpC,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB,gCA4DA"}
1
+ {"version":3,"file":"source-code.d.ts","sourceRoot":"","sources":["../../../source/features/source-code.ts"],"names":[],"mappings":"AAEA,OAAc,EAAC,KAAK,6BAA6B,EAAC,MAAM,sBAAsB,CAAC;AAE/E,OAAO,KAAK,EAAC,OAAO,IAAI,gBAAgB,EAAC,MAAM,mBAAmB,CAAC;AAInE,wBAAgB,UAAU,CAAC,EACzB,IAAI,EACJ,OAAO,EACP,KAAY,EACZ,KAAK,EAAE,QAAe,GACvB,EAAE;IACD,IAAI,CAAC,EAAE,aAAa,GAAG,YAAY,CAAC;IACpC,KAAK,CAAC,EAAE,OAAO,GAAG,OAAO,GAAG,QAAQ,CAAC;IACrC,OAAO,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAC5B,KAAK,CAAC,EACF,OAAO,GACP;QACE,WAAW,CAAC,EAAE,gBAAgB,CAAC,aAAa,CAAC,CAAC;QAC9C,OAAO,CAAC,CACN,OAAO,EAAE,6BAA6B,GACrC,6BAA6B,GAAG,IAAI,CAAC;KACzC,CAAC;CACP,gCAoEA"}
@@ -2,6 +2,9 @@ export declare function systemJS({ minify }?: {
2
2
  minify?: boolean | undefined;
3
3
  }): {
4
4
  name: string;
5
- renderChunk(this: import("rollup").PluginContext, _: string, chunk: import("rollup").RenderedChunk, options: import("rollup").NormalizedOutputOptions): Promise<null>;
5
+ renderChunk(this: import("rollup").PluginContext, code: string, chunk: import("rollup").RenderedChunk, options: import("rollup").NormalizedOutputOptions): Promise<{
6
+ code: string;
7
+ map: import("magic-string").SourceMap;
8
+ } | null>;
6
9
  };
7
10
  //# sourceMappingURL=system-js.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"system-js.d.ts","sourceRoot":"","sources":["../../../source/features/system-js.ts"],"names":[],"mappings":"AAKA,wBAAgB,QAAQ,CAAC,EAAC,MAAc,EAAC;;CAAK;;;EA8B7C"}
1
+ {"version":3,"file":"system-js.d.ts","sourceRoot":"","sources":["../../../source/features/system-js.ts"],"names":[],"mappings":"AAQA,wBAAgB,QAAQ,CAAC,EAAC,MAAc,EAAC;;CAAK;;;;;;EAkD7C"}
@@ -0,0 +1,52 @@
1
+ import type { Plugin, InputOptions, OutputOptions, OutputChunk } from 'rollup';
2
+ export interface WorkerWrapper {
3
+ readonly module: string;
4
+ readonly function: string;
5
+ }
6
+ export interface WorkerContext {
7
+ readonly module: string;
8
+ readonly wrapper: WorkerWrapper;
9
+ }
10
+ export interface BaseURLContext extends WorkerContext {
11
+ readonly filename: string;
12
+ readonly chunk: OutputChunk;
13
+ readonly outputOptions: OutputOptions;
14
+ }
15
+ export type ValueOrGetter<T, Context extends WorkerContext = WorkerContext> = T | ((context: Context) => T | Promise<T>);
16
+ export type ValueOrUpdateGetter<T, Context extends WorkerContext = WorkerContext> = T | ((current: T, context: Context) => T | Promise<T>);
17
+ export interface Options {
18
+ /**
19
+ * By default, this plugin uses `rollup().generate()` and attaches the
20
+ * resulting in-memory chunk to your main rollup build. When rolling rollup
21
+ * normally, this will output your asset to the file system when the main
22
+ * rollup build calls `write()`. Some tools that wrap rollup, like Vite, do
23
+ * don’t really call `write()`, so I can’t figure out how to make this approach
24
+ * work with them. In those instances, you can instead pass `write: true` here,
25
+ * which will then run `rollup().write()` on the worker bundle to actually output
26
+ * it to the filesystem (you can customize the output with the `outputOptions`
27
+ * option). You can then use the `baseURL()` option to control the URL that is
28
+ * generated for each worker module such that the tool is able to route that request
29
+ * to the written file. For example, in Vite, you can use the special `/@fs` prefix
30
+ * for a URL:
31
+ *
32
+ * ```ts
33
+ * import * as path from 'path';
34
+ *
35
+ * workers({
36
+ * write: true,
37
+ * baseURL({filename, outputOptions}) {
38
+ * return `/@fs${path.join(outputOptions.dir, filename)}`;
39
+ * },
40
+ * })
41
+ * ```
42
+ */
43
+ write?: ValueOrGetter<boolean>;
44
+ plugins?: ValueOrUpdateGetter<Plugin[]>;
45
+ inputOptions?: ValueOrUpdateGetter<InputOptions>;
46
+ outputOptions?: ValueOrUpdateGetter<OutputOptions>;
47
+ contentForWorker?: ValueOrGetter<string | undefined>;
48
+ baseURL?: ValueOrGetter<string | undefined, BaseURLContext>;
49
+ onIncludeFile?(file: string, worker: string): void;
50
+ }
51
+ export declare function workers({ write, baseURL, contentForWorker, plugins, inputOptions, outputOptions, onIncludeFile, }?: Options): Plugin;
52
+ //# sourceMappingURL=workers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"workers.d.ts","sourceRoot":"","sources":["../../../source/features/workers.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EACV,MAAM,EACN,YAAY,EACZ,aAAa,EACb,WAAW,EAEZ,MAAM,QAAQ,CAAC;AAQhB,MAAM,WAAW,aAAa;IAC5B,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;CAC3B;AAED,MAAM,WAAW,aAAa;IAC5B,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,OAAO,EAAE,aAAa,CAAC;CACjC;AAED,MAAM,WAAW,cAAe,SAAQ,aAAa;IACnD,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,KAAK,EAAE,WAAW,CAAC;IAC5B,QAAQ,CAAC,aAAa,EAAE,aAAa,CAAC;CACvC;AAED,MAAM,MAAM,aAAa,CAAC,CAAC,EAAE,OAAO,SAAS,aAAa,GAAG,aAAa,IACtE,CAAC,GACD,CAAC,CAAC,OAAO,EAAE,OAAO,KAAK,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC;AAE3C,MAAM,MAAM,mBAAmB,CAC7B,CAAC,EACD,OAAO,SAAS,aAAa,GAAG,aAAa,IAC3C,CAAC,GAAG,CAAC,CAAC,OAAO,EAAE,CAAC,EAAE,OAAO,EAAE,OAAO,KAAK,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC;AAE3D,MAAM,WAAW,OAAO;IACtB;;;;;;;;;;;;;;;;;;;;;;;;OAwBG;IACH,KAAK,CAAC,EAAE,aAAa,CAAC,OAAO,CAAC,CAAC;IAC/B,OAAO,CAAC,EAAE,mBAAmB,CAAC,MAAM,EAAE,CAAC,CAAC;IACxC,YAAY,CAAC,EAAE,mBAAmB,CAAC,YAAY,CAAC,CAAC;IACjD,aAAa,CAAC,EAAE,mBAAmB,CAAC,aAAa,CAAC,CAAC;IACnD,gBAAgB,CAAC,EAAE,aAAa,CAAC,MAAM,GAAG,SAAS,CAAC,CAAC;IACrD,OAAO,CAAC,EAAE,aAAa,CAAC,MAAM,GAAG,SAAS,EAAE,cAAc,CAAC,CAAC;IAC5D,aAAa,CAAC,CAAC,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC;CACpD;AAED,wBAAgB,OAAO,CAAC,EACtB,KAAa,EACb,OAAO,EACP,gBAA0C,EAC1C,OAAwB,EACxB,YAAiB,EACjB,aAAkB,EAClB,aAAa,GACd,GAAE,OAAY,GAAG,MAAM,CAsJvB"}
@@ -1,4 +1,5 @@
1
- export { quiltAppBrowser, quiltAppServer, type AppOptions, type AppBrowserOptions, type AppServerOptions, } from './app.ts';
1
+ export { quiltApp, quiltAppBrowser, quiltAppServer, type AppOptions, type AppBaseOptions, type AppBrowserOptions, type AppServerOptions, } from './app.ts';
2
2
  export { quiltModule, type ModuleOptions } from './module.ts';
3
- export { quiltPackageESModules, quiltPackageESNext, type PackageOptions, } from './package.ts';
3
+ export { quiltPackage, quiltPackageESModules, quiltPackageESNext, type PackageOptions, } from './package.ts';
4
+ export { quiltServer, type ServerOptions } from './server.ts';
4
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../source/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,eAAe,EACf,cAAc,EACd,KAAK,UAAU,EACf,KAAK,iBAAiB,EACtB,KAAK,gBAAgB,GACtB,MAAM,UAAU,CAAC;AAClB,OAAO,EAAC,WAAW,EAAE,KAAK,aAAa,EAAC,MAAM,aAAa,CAAC;AAC5D,OAAO,EACL,qBAAqB,EACrB,kBAAkB,EAClB,KAAK,cAAc,GACpB,MAAM,cAAc,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../source/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EACR,eAAe,EACf,cAAc,EACd,KAAK,UAAU,EACf,KAAK,cAAc,EACnB,KAAK,iBAAiB,EACtB,KAAK,gBAAgB,GACtB,MAAM,UAAU,CAAC;AAClB,OAAO,EAAC,WAAW,EAAE,KAAK,aAAa,EAAC,MAAM,aAAa,CAAC;AAC5D,OAAO,EACL,YAAY,EACZ,qBAAqB,EACrB,kBAAkB,EAClB,KAAK,cAAc,GACpB,MAAM,cAAc,CAAC;AACtB,OAAO,EAAC,WAAW,EAAE,KAAK,aAAa,EAAC,MAAM,aAAa,CAAC"}
@@ -1,11 +1,21 @@
1
1
  import { Plugin } from 'rollup';
2
- import { type BrowserTargetSelection } from './shared/browserslist.ts';
3
- import type { MagicModuleEnvOptions } from './features/env.ts';
2
+ import { RollupNodePluginOptions } from './shared/rollup.ts';
3
+ import { type BrowserGroupTargetSelection } from './shared/browserslist.ts';
4
+ import { type MagicModuleEnvOptions } from './features/env.ts';
4
5
  export interface ModuleOptions {
5
6
  /**
6
7
  * The root directory containing the source code for your application.
7
8
  */
8
9
  root?: string | URL;
10
+ /**
11
+ * The entry module for this module. This should be an absolute path, or relative
12
+ * path from the root directory containing your project. If not provided, this
13
+ * defaults the `main` or `exports['.']` field in your package.json, or a file named
14
+ * `index`, `module`, `entry`, or `input` in your project root.
15
+ *
16
+ * @example './my-module.tsx'
17
+ */
18
+ entry?: string;
9
19
  /**
10
20
  * Whether to include GraphQL-related code transformations.
11
21
  *
@@ -15,13 +25,13 @@ export interface ModuleOptions {
15
25
  /**
16
26
  * Customizes the behavior of environment variables for your module.
17
27
  */
18
- env?: MagicModuleEnvOptions;
28
+ env?: MagicModuleEnvOptions | MagicModuleEnvOptions['mode'];
19
29
  /**
20
30
  * Customizes the assets created for your module.
21
31
  */
22
32
  assets?: ModuleAssetsOptions;
23
33
  }
24
- export interface ModuleAssetsOptions {
34
+ export interface ModuleAssetsOptions extends Pick<RollupNodePluginOptions, 'bundle'> {
25
35
  /**
26
36
  * Whether to minify assets created for this module.
27
37
  *
@@ -29,9 +39,9 @@ export interface ModuleAssetsOptions {
29
39
  */
30
40
  minify?: boolean;
31
41
  hash?: boolean | 'async-only';
32
- targets?: BrowserTargetSelection;
42
+ targets?: BrowserGroupTargetSelection;
33
43
  }
34
- export declare function quiltModule({ root: rootPath, env, assets, graphql, }?: ModuleOptions): Promise<{
44
+ export declare function quiltModule({ root: rootPath, entry, env, assets, graphql, }?: ModuleOptions): Promise<{
35
45
  input: string;
36
46
  plugins: Plugin<any>[];
37
47
  onwarn(warning: import("rollup").RollupLog, defaultWarn: import("rollup").LoggingFunction): void;
@@ -41,6 +51,14 @@ export declare function quiltModule({ root: rootPath, env, assets, graphql, }?:
41
51
  entryFileNames: string;
42
52
  chunkFileNames: string;
43
53
  assetFileNames: string;
54
+ generatedCode: {
55
+ preset: "es2015";
56
+ arrowFunctions: boolean;
57
+ constBindings: boolean;
58
+ objectShorthand: boolean;
59
+ reservedNamesAsProps: boolean;
60
+ symbols: boolean;
61
+ };
44
62
  };
45
63
  }>;
46
64
  //# sourceMappingURL=module.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"module.d.ts","sourceRoot":"","sources":["../../source/module.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,MAAM,EAAqB,MAAM,QAAQ,CAAC;AAMlD,OAAO,EAEL,KAAK,sBAAsB,EAC5B,MAAM,0BAA0B,CAAC;AAClC,OAAO,KAAK,EAAC,qBAAqB,EAAC,MAAM,mBAAmB,CAAC;AAE7D,MAAM,WAAW,aAAa;IAC5B;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,GAAG,GAAG,CAAC;IAEpB;;;;OAIG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;OAEG;IACH,GAAG,CAAC,EAAE,qBAAqB,CAAC;IAE5B;;OAEG;IACH,MAAM,CAAC,EAAE,mBAAmB,CAAC;CAC9B;AAED,MAAM,WAAW,mBAAmB;IAClC;;;;OAIG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,IAAI,CAAC,EAAE,OAAO,GAAG,YAAY,CAAC;IAC9B,OAAO,CAAC,EAAE,sBAAsB,CAAC;CAClC;AAED,wBAAsB,WAAW,CAAC,EAChC,IAAI,EAAE,QAAwB,EAC9B,GAAG,EACH,MAAM,EACN,OAAc,GACf,GAAE,aAAkB;;;;;;;;;;;GAwFpB"}
1
+ {"version":3,"file":"module.d.ts","sourceRoot":"","sources":["../../source/module.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,MAAM,EAAqB,MAAM,QAAQ,CAAC;AAIlD,OAAO,EACL,uBAAuB,EAGxB,MAAM,oBAAoB,CAAC;AAE5B,OAAO,EAGL,KAAK,2BAA2B,EACjC,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAAmB,KAAK,qBAAqB,EAAC,MAAM,mBAAmB,CAAC;AAE/E,MAAM,WAAW,aAAa;IAC5B;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,GAAG,GAAG,CAAC;IAEpB;;;;;;;OAOG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;;;OAIG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