Skip to content

Commit f836503

Browse files
committed
chore: add a new html to rollup and update the existent one to work with dev esbuild
1 parent 6322ba7 commit f836503

File tree

3 files changed

+22
-3
lines changed

3 files changed

+22
-3
lines changed

public/index-rollup.html

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8" />
5+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
6+
<meta name="theme-color" content="#009ee2" />
7+
8+
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
9+
<title>Dev - React Tooltip</title>
10+
<link rel="stylesheet" href="index.css" />
11+
</head>
12+
<body>
13+
<noscript>You need to enable JavaScript to run this app. Please enable JavaScript 😭</noscript>
14+
15+
<div id="app"></div>
16+
17+
<script type="module" src="<%= appBundle %>"></script>
18+
</body>
19+
</html>

public/index.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,13 @@
77

88
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
99
<title>Dev - React Tooltip</title>
10-
<link rel="stylesheet" href="index.css" />
10+
<link rel="stylesheet" href="/index-dev.css" />
1111
</head>
1212
<body>
1313
<noscript>You need to enable JavaScript to run this app. Please enable JavaScript 😭</noscript>
1414

1515
<div id="app"></div>
1616

17-
<script type="module" src="<%= appBundle %>"></script>
17+
<script type="module" src="/index-dev.js"></script>
1818
</body>
1919
</html>

rollup.config.dev.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ const globals = {
2525
const plugins = [
2626
progress(),
2727
html({
28-
input: './public/index.html',
28+
input: './public/index-rollup.html',
2929
output: './build/index.html',
3030
template: { appBundle: 'index.js' },
3131
}),

0 commit comments

Comments
 (0)