feat(docs): make webpack-getting-started more universal (#7191)

This commit is contained in:
Костя Третяк
2021-04-21 00:16:53 +03:00
committed by GitHub
parent 92f1507408
commit f239965cbc

View File

@@ -8,7 +8,10 @@ const outputPath = path.resolve(__dirname, 'dist');
module.exports = {
mode: 'development',
entry: {
app: './src/index.js',
app: require.resolve('./src/index'),
},
resolve: {
extensions: ['.ts', '.js'],
},
module: {
rules: [
@@ -36,7 +39,7 @@ module.exports = {
{
// Copy the Swagger OAuth2 redirect file to the project root;
// that file handles the OAuth2 redirect after authenticating the end-user.
from: 'node_modules/swagger-ui/dist/oauth2-redirect.html',
from: require.resolve('swagger-ui/dist/oauth2-redirect.html'),
to: './'
}
]),