@konomi-app/k2 0.3.0 → 0.3.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.
|
@@ -6,7 +6,7 @@ import base from './build-vite-base.js';
|
|
|
6
6
|
import fs from 'fs-extra';
|
|
7
7
|
export default function command() {
|
|
8
8
|
program
|
|
9
|
-
.command('build')
|
|
9
|
+
.command('vite-build')
|
|
10
10
|
.option('-o, --outdir <outdir>', 'Output directory.', path.join(WORKSPACE_DIRECTORY, 'prod'))
|
|
11
11
|
.option('-i, --input <input>', 'Input directory.', path.join('src', 'apps'))
|
|
12
12
|
.description("Build the project for production. (It's a wrapper of webpack build command.)")
|
package/dist/index.js
CHANGED
|
@@ -3,7 +3,7 @@ import { program } from 'commander';
|
|
|
3
3
|
import build from './commands/build.js';
|
|
4
4
|
import viteBuild from './commands/build-vite.js';
|
|
5
5
|
import dev from './commands/dev.js';
|
|
6
|
-
import viteDev from './commands/vite
|
|
6
|
+
import viteDev from './commands/dev-vite.js';
|
|
7
7
|
import genkey from './commands/genkey.js';
|
|
8
8
|
program.name('k2').version('0.1.0').description('k2 - 🍳 kintone kitchen 🍳');
|
|
9
9
|
build();
|
package/dist/lib/vite.js
CHANGED
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import path from 'path';
|
|
2
|
-
import { PLUGIN_DEVELOPMENT_DIRECTORY } from './constants.js';
|
|
3
2
|
import tsconfigPaths from 'vite-tsconfig-paths';
|
|
4
3
|
export const getViteConfig = (config) => {
|
|
5
4
|
return {
|
|
5
|
+
...config,
|
|
6
6
|
configFile: false,
|
|
7
7
|
build: {
|
|
8
|
-
|
|
9
|
-
emptyOutDir: true,
|
|
8
|
+
...config.build,
|
|
10
9
|
rollupOptions: {
|
|
11
10
|
...config.build?.rollupOptions,
|
|
12
11
|
onwarn: (warning, warn) => {
|
|
@@ -17,9 +16,9 @@ export const getViteConfig = (config) => {
|
|
|
17
16
|
},
|
|
18
17
|
},
|
|
19
18
|
},
|
|
20
|
-
plugins: [tsconfigPaths()],
|
|
21
|
-
server: config.server,
|
|
19
|
+
plugins: [...(config.plugins ?? []), tsconfigPaths()],
|
|
22
20
|
resolve: {
|
|
21
|
+
...config.resolve,
|
|
23
22
|
alias: { '@': path.resolve('src') },
|
|
24
23
|
},
|
|
25
24
|
};
|
package/package.json
CHANGED
|
File without changes
|