mirror of
https://github.com/hodgef/simple-keyboard.git
synced 2025-02-22 01:29:39 +08:00
Copy index.d.ts to build folder on build
This commit is contained in:
parent
ff037ad5b7
commit
b3b482e864
@ -79,6 +79,7 @@ module.exports = {
|
|||||||
appPackageJson: resolveApp('package.json'),
|
appPackageJson: resolveApp('package.json'),
|
||||||
appSrc: resolveApp('src'),
|
appSrc: resolveApp('src'),
|
||||||
appSrcLib: resolveApp('src/lib'),
|
appSrcLib: resolveApp('src/lib'),
|
||||||
|
appSrcLibTypes: resolveApp('src/lib/@types'),
|
||||||
appSrcDemo: resolveApp('src/demo'),
|
appSrcDemo: resolveApp('src/demo'),
|
||||||
appTsConfig: resolveApp('tsconfig.json'),
|
appTsConfig: resolveApp('tsconfig.json'),
|
||||||
yarnLockFile: resolveApp('yarn.lock'),
|
yarnLockFile: resolveApp('yarn.lock'),
|
||||||
|
@ -21,6 +21,7 @@ const getClientEnvironment = require('./env');
|
|||||||
const ModuleNotFoundPlugin = require('react-dev-utils/ModuleNotFoundPlugin');
|
const ModuleNotFoundPlugin = require('react-dev-utils/ModuleNotFoundPlugin');
|
||||||
const ForkTsCheckerWebpackPlugin = require('fork-ts-checker-webpack-plugin-alt');
|
const ForkTsCheckerWebpackPlugin = require('fork-ts-checker-webpack-plugin-alt');
|
||||||
const typescriptFormatter = require('react-dev-utils/typescriptFormatter');
|
const typescriptFormatter = require('react-dev-utils/typescriptFormatter');
|
||||||
|
const CopyWebpackPlugin = require('copy-webpack-plugin');
|
||||||
const getPackageJson = require('./getPackageJson');
|
const getPackageJson = require('./getPackageJson');
|
||||||
|
|
||||||
|
|
||||||
@ -510,6 +511,12 @@ module.exports = {
|
|||||||
// https://github.com/jmblog/how-to-optimize-momentjs-with-webpack
|
// https://github.com/jmblog/how-to-optimize-momentjs-with-webpack
|
||||||
// You can remove this if you don't use Moment.js:
|
// You can remove this if you don't use Moment.js:
|
||||||
new webpack.IgnorePlugin(/^\.\/locale$/, /moment$/),
|
new webpack.IgnorePlugin(/^\.\/locale$/, /moment$/),
|
||||||
|
new CopyWebpackPlugin([
|
||||||
|
{
|
||||||
|
from: `${paths.appSrcLibTypes}`,
|
||||||
|
to: paths.appLayoutsBuild
|
||||||
|
}
|
||||||
|
]),
|
||||||
// Generate a service worker script that will precache, and keep up to date,
|
// Generate a service worker script that will precache, and keep up to date,
|
||||||
// the HTML & assets that are part of the Webpack build.
|
// the HTML & assets that are part of the Webpack build.
|
||||||
/*new WorkboxWebpackPlugin.GenerateSW({
|
/*new WorkboxWebpackPlugin.GenerateSW({
|
||||||
|
Loading…
Reference in New Issue
Block a user