extwee 2.3.2 → 2.3.4
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.
- package/build/extwee.core.min.js +1 -0
- package/build/extwee.twine1html.min.js +1 -0
- package/build/extwee.twine2archive.min.js +1 -0
- package/build/extwee.tws.min.js +1 -0
- package/build/test-modular.html +126 -0
- package/docs/build/extwee.core.min.js +1 -0
- package/docs/build/extwee.twine1html.min.js +1 -0
- package/docs/build/extwee.twine2archive.min.js +1 -0
- package/docs/build/extwee.tws.min.js +1 -0
- package/docs/demos/compiler/extwee.core.min.js +1 -0
- package/docs/demos/compiler/index.css +105 -0
- package/docs/demos/compiler/index.html +359 -0
- package/eslint.config.js +4 -1
- package/package.json +25 -22
- package/src/IFID/generate.js +2 -2
- package/src/Story.js +1 -1
- package/src/Twine1HTML/parse-web.js +255 -0
- package/src/Twine2ArchiveHTML/parse-web.js +134 -0
- package/src/Twine2HTML/parse-web.js +434 -0
- package/src/Web/web-core.js +51 -0
- package/src/Web/web-twine1html.js +35 -0
- package/src/Web/web-twine2archive.js +35 -0
- package/src/Web/web-tws.js +30 -0
- package/test/Config/Config.test.js +1 -1
- package/test/Config/isDirectory.test.js +15 -9
- package/test/Config/isFile.test.js +14 -11
- package/test/Config/loadStoryFormat.test.js +49 -33
- package/test/Config/readDirectories.test.js +25 -15
- package/test/Objects/Story.test.js +1 -0
- package/test/StoryFormat/StoryFormat.Parse.test.js +1 -0
- package/test/Twine1HTML/Twine1HTML.Parse.Web.test.js +484 -0
- package/test/Twine2ArchiveHTML/Twine2ArchiveHTML.Parse.Web.test.js +293 -0
- package/test/Twine2ArchiveHTML/Twine2ArchiveHTML.Parse.test.js +1 -0
- package/test/Twine2HTML/Twine2HTML.Parse.Web.test.js +329 -0
- package/test/Twine2HTML/Twine2HTML.Parse.test.js +1 -0
- package/test/Web/web-core-coverage.test.js +175 -0
- package/test/Web/web-core-global.test.js +93 -0
- package/test/Web/web-core.test.js +156 -0
- package/test/Web/window.Extwee.test.js +25 -13
- package/types/src/Story.d.ts +1 -1
- package/types/src/Twine1HTML/parse-web.d.ts +10 -0
- package/types/src/Twine2ArchiveHTML/parse-web.d.ts +37 -0
- package/types/src/Twine2HTML/parse-web.d.ts +21 -0
- package/types/src/Web/html-entities-lite.d.ts +12 -0
- package/types/src/Web/semver-lite.d.ts +10 -0
- package/types/src/Web/uuid-lite.d.ts +6 -0
- package/types/src/Web/web-core.d.ts +23 -0
- package/types/src/Web/web-index.d.ts +1 -0
- package/types/src/Web/web-twine1html.d.ts +10 -0
- package/types/src/Web/web-twine2archive.d.ts +10 -0
- package/types/src/Web/web-tws.d.ts +7 -0
- package/webpack.config.js +23 -2
- package/build/extwee.web.min.js +0 -2
- package/build/extwee.web.min.js.LICENSE.txt +0 -1
- package/web-index.js +0 -31
package/webpack.config.js
CHANGED
|
@@ -3,10 +3,31 @@ import path from 'node:path';
|
|
|
3
3
|
export default {
|
|
4
4
|
mode: 'production',
|
|
5
5
|
entry: {
|
|
6
|
-
|
|
6
|
+
// Core bundle with most common functionality
|
|
7
|
+
'extwee.core': './src/Web/web-core.js',
|
|
8
|
+
// Individual parser modules
|
|
9
|
+
'extwee.twine1html': './src/Web/web-twine1html.js',
|
|
10
|
+
'extwee.twine2archive': './src/Web/web-twine2archive.js',
|
|
11
|
+
'extwee.tws': './src/Web/web-tws.js'
|
|
7
12
|
},
|
|
8
13
|
output: {
|
|
9
14
|
path: path.resolve('./', 'build'),
|
|
10
|
-
filename: '[name].js',
|
|
15
|
+
filename: '[name].min.js',
|
|
16
|
+
library: {
|
|
17
|
+
type: 'umd',
|
|
18
|
+
name: 'Extwee', // Use a single library name for all modules
|
|
19
|
+
export: 'default' // Export the default export directly
|
|
20
|
+
},
|
|
21
|
+
globalObject: 'this'
|
|
11
22
|
},
|
|
23
|
+
optimization: {
|
|
24
|
+
usedExports: true,
|
|
25
|
+
sideEffects: false,
|
|
26
|
+
splitChunks: false // Don't split chunks for individual modules
|
|
27
|
+
},
|
|
28
|
+
performance: {
|
|
29
|
+
maxAssetSize: 250000, // 244 KiB
|
|
30
|
+
maxEntrypointSize: 250000,
|
|
31
|
+
hints: 'warning'
|
|
32
|
+
}
|
|
12
33
|
};
|