Skip to content

Commit

Permalink
Fix E2E chunks for Playwright
Browse files Browse the repository at this point in the history
  • Loading branch information
luin committed Nov 26, 2023
1 parent 0e74eed commit 94b4717
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 3 deletions.
4 changes: 2 additions & 2 deletions packages/quill/playwright.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@ export default defineConfig({
{ name: 'Safari', use: { ...devices['Desktop Safari'] } },
],
webServer: {
command: `npx webpack serve --config test/e2e/__dev_server__/webpack.config.js --env port=${port}`,
command: `npx webpack serve --config test/e2e/__dev_server__/webpack.config.ts --env port=${port}`,
port,
ignoreHTTPSErrors: true,
reuseExistingServer: !process.env.CI,
stdout: 'ignore',
stderr: 'ignore',
stderr: 'pipe',
},
});
2 changes: 2 additions & 0 deletions packages/quill/test/e2e/__dev_server__/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
<title>Quill E2E Tests</title>
<script src="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/highlight.min.js"></script>
<link href="/quill.core.css" rel="stylesheet">
<link href="/quill.snow.css" rel="stylesheet">
</head>

<body>
Expand Down
3 changes: 2 additions & 1 deletion packages/quill/test/e2e/__dev_server__/webpack.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import HtmlWebpackPlugin from 'html-webpack-plugin';
import common from '../../../webpack.common';
import { merge } from 'webpack-merge';
import type { Configuration } from 'webpack';
import 'webpack-dev-server';

export default (env: Record<string, unknown>) =>
merge<Configuration>(common, {
Expand All @@ -11,7 +12,7 @@ export default (env: Record<string, unknown>) =>
publicPath: '/',
filename: 'index.html',
template: path.resolve(__dirname, 'index.html'),
chunks: ['quill.js', 'quill.core', 'quill.snow'],
chunks: ['quill'],
inject: 'head',
scriptLoading: 'blocking',
}),
Expand Down
1 change: 1 addition & 0 deletions packages/quill/webpack.common.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ export default {
library: {
name: 'Quill',
type: 'umd',
export: 'default',
},
path: resolve(__dirname, 'dist/dist'),
clean: true,
Expand Down

0 comments on commit 94b4717

Please sign in to comment.