histoire 0.15.5 → 0.15.7
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/dist/node/server.js +4 -6
- package/dist/node/vite.js +1 -5
- package/package.json +5 -5
- package/src/node/server.ts +4 -11
- package/src/node/vite.ts +1 -5
package/dist/node/server.js
CHANGED
|
@@ -22,12 +22,10 @@ export async function createServer(ctx, options = {}) {
|
|
|
22
22
|
viteConfigFile,
|
|
23
23
|
};
|
|
24
24
|
};
|
|
25
|
-
const
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
createMarkdownFilesWatcher(ctx),
|
|
30
|
-
]);
|
|
25
|
+
const { server, viteConfigFile } = await getViteServer(false);
|
|
26
|
+
const { server: nodeServer } = await getViteServer(true); // Should be run after the first one to get a fresh vite.config.js
|
|
27
|
+
await watchStories(ctx);
|
|
28
|
+
const { stop: stopMdFileWatcher } = await createMarkdownFilesWatcher(ctx);
|
|
31
29
|
const moduleLoader = useModuleLoader({
|
|
32
30
|
server: nodeServer,
|
|
33
31
|
});
|
package/dist/node/vite.js
CHANGED
|
@@ -112,11 +112,7 @@ export async function getViteConfigWithPlugins(isServer, ctx) {
|
|
|
112
112
|
watch: {
|
|
113
113
|
ignored: [`!**/node_modules/.histoire/**`, '**/vite.config.*'],
|
|
114
114
|
},
|
|
115
|
-
|
|
116
|
-
? {
|
|
117
|
-
hmr: false,
|
|
118
|
-
}
|
|
119
|
-
: {},
|
|
115
|
+
hmr: !isServer,
|
|
120
116
|
},
|
|
121
117
|
define: {
|
|
122
118
|
// We need to force this to be able to use `devtoolsRawSetupState`
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "histoire",
|
|
3
|
-
"version": "0.15.
|
|
3
|
+
"version": "0.15.7",
|
|
4
4
|
"description": "A fast story book powered by Vite",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": {
|
|
@@ -38,10 +38,10 @@
|
|
|
38
38
|
},
|
|
39
39
|
"dependencies": {
|
|
40
40
|
"@akryum/tinypool": "^0.3.1",
|
|
41
|
-
"@histoire/app": "^0.15.
|
|
42
|
-
"@histoire/controls": "^0.15.
|
|
43
|
-
"@histoire/shared": "^0.15.
|
|
44
|
-
"@histoire/vendors": "^0.15.
|
|
41
|
+
"@histoire/app": "^0.15.7",
|
|
42
|
+
"@histoire/controls": "^0.15.7",
|
|
43
|
+
"@histoire/shared": "^0.15.7",
|
|
44
|
+
"@histoire/vendors": "^0.15.7",
|
|
45
45
|
"@types/flexsearch": "^0.7.3",
|
|
46
46
|
"@types/markdown-it": "^12.2.3",
|
|
47
47
|
"birpc": "^0.1.1",
|
package/src/node/server.ts
CHANGED
|
@@ -33,17 +33,10 @@ export async function createServer (ctx: Context, options: CreateServerOptions =
|
|
|
33
33
|
}
|
|
34
34
|
}
|
|
35
35
|
|
|
36
|
-
const
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
{ stop: stopMdFileWatcher },
|
|
41
|
-
] = await Promise.all([
|
|
42
|
-
getViteServer(false),
|
|
43
|
-
getViteServer(true),
|
|
44
|
-
watchStories(ctx),
|
|
45
|
-
createMarkdownFilesWatcher(ctx),
|
|
46
|
-
] as const)
|
|
36
|
+
const { server, viteConfigFile } = await getViteServer(false)
|
|
37
|
+
const { server: nodeServer } = await getViteServer(true) // Should be run after the first one to get a fresh vite.config.js
|
|
38
|
+
await watchStories(ctx)
|
|
39
|
+
const { stop: stopMdFileWatcher } = await createMarkdownFilesWatcher(ctx)
|
|
47
40
|
|
|
48
41
|
const moduleLoader = useModuleLoader({
|
|
49
42
|
server: nodeServer,
|
package/src/node/vite.ts
CHANGED
|
@@ -134,11 +134,7 @@ export async function getViteConfigWithPlugins (isServer: boolean, ctx: Context)
|
|
|
134
134
|
watch: {
|
|
135
135
|
ignored: [`!**/node_modules/.histoire/**`, '**/vite.config.*'],
|
|
136
136
|
},
|
|
137
|
-
|
|
138
|
-
? {
|
|
139
|
-
hmr: false,
|
|
140
|
-
}
|
|
141
|
-
: {},
|
|
137
|
+
hmr: !isServer,
|
|
142
138
|
},
|
|
143
139
|
define: {
|
|
144
140
|
// We need to force this to be able to use `devtoolsRawSetupState`
|