Skip to content

Commit f5f8248

Browse files
committed
Moved from CRA to Vite
1 parent eafd122 commit f5f8248

20 files changed

+4000
-12287
lines changed

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,4 +22,6 @@
2222

2323
npm-debug.log*
2424
yarn-debug.log*
25-
yarn-error.log*
25+
yarn-error.log*
26+
27+
/dist

config-overrides.js

Lines changed: 0 additions & 12 deletions
This file was deleted.

public/index.html renamed to index.html

Lines changed: 4 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -3,18 +3,18 @@
33

44
<head>
55
<meta charset="utf-8" />
6-
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
6+
<link rel="icon" href="/favicon.ico" />
77
<meta name="viewport" content="width=device-width, initial-scale=1" />
88
<meta name="theme-color" content="#000000" />
99
<meta name="description" content="Online code editor and compiler" />
10-
<link rel="apple-touch-icon" href="%PUBLIC_URL%/images/logo192.png" />
10+
<link rel="apple-touch-icon" href="/images/logo192.png" />
1111
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.1/css/all.min.css"
1212
crossorigin="anonymous" />
1313
<!--
1414
manifest.json provides metadata used when your web app is installed on a
1515
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
1616
-->
17-
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
17+
<link rel="manifest" href="/manifest.json" />
1818
<link href="https://fonts.googleapis.com/css2?family=Comfortaa:wght@700&display=swap" rel="stylesheet">
1919
<!--
2020
Notice the use of %PUBLIC_URL% in the tags above.
@@ -127,31 +127,7 @@ <h1 class="loading">LOADING</h1>
127127
<div class="line"></div>
128128
</div>
129129
</div>
130-
<!--
131-
This HTML file is a template.
132-
If you open it directly in the browser, you will see an empty page.
133-
134-
You can add webfonts, meta tags, or analytics to this file.
135-
The build step will place the bundled scripts into the <body> tag.
136-
137-
To begin the development, run `npm start` or `yarn start`.
138-
To create a production bundle, use `npm run build` or `yarn build`.
139-
-->
140-
<!-- <script>
141-
if ('serviceWorker' in navigator) {
142-
window.addEventListener('load', function () {
143-
navigator.serviceWorker.register('worker.js').then(function (registration) {
144-
console.log('Service Worker registration successful', registration.scope);
145-
}, function (err) {
146-
console.log('Service Worker registration failed', err);
147-
}).catch(function (err) {
148-
console.log(err);
149-
});
150-
});
151-
} else {
152-
console.log('Service Worker is not supported by browser.');
153-
}
154-
</script> -->
130+
<script type="module" src="/src/index.jsx"></script>
155131
</body>
156132

157133
</html>

package.json

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -7,33 +7,34 @@
77
"@testing-library/jest-dom": "^4.2.4",
88
"@testing-library/react": "^9.3.2",
99
"@testing-library/user-event": "^7.1.2",
10+
"@vitejs/plugin-react-swc": "^3.10.2",
1011
"axios": "^0.21.0",
1112
"baseui": "^9.104.0",
12-
"monaco-editor-webpack-plugin": "^2.0.0",
13+
"monaco-editor": "^0.49.0",
1314
"monaco-vim": "^0.1.8",
15+
"prop-types": "^15.8.1",
1416
"react": "^17.0.1",
1517
"react-dom": "^17.0.1",
1618
"react-github-corner": "^2.5.0",
1719
"react-monaco-editor": "^0.40.0",
1820
"react-redux": "^7.2.2",
1921
"react-resize-detector": "^5.2.0",
20-
"react-scripts": "4.0.0",
2122
"react-select": "^3.1.0",
2223
"react-spinners-kit": "^1.9.1",
2324
"react-split-pane": "^0.1.92",
25+
"redux": "^5.0.1",
2426
"redux-devtools-extension": "^2.13.8",
2527
"redux-persist": "^6.0.0",
2628
"styletron-engine-atomic": "^1.4.6",
27-
"styletron-react": "^5.2.7"
29+
"styletron-react": "^5.2.7",
30+
"vite": "^6.3.5",
31+
"vite-plugin-svgr": "^4.3.0",
32+
"vite-tsconfig-paths": "^5.1.4"
2833
},
2934
"scripts": {
30-
"start": "react-app-rewired start",
31-
"build": "react-app-rewired build",
32-
"test": "react-app-rewired test",
33-
"eject": "react-scripts eject"
34-
},
35-
"eslintConfig": {
36-
"extends": "react-app"
35+
"start": "vite",
36+
"build": "vite build",
37+
"dev": "vite preview"
3738
},
3839
"browserslist": {
3940
"production": [
@@ -49,6 +50,6 @@
4950
},
5051
"devDependencies": {
5152
"eslint-plugin-baseui": "^9.104.0",
52-
"react-app-rewired": "^2.1.6"
53+
"vite-plugin-monaco-editor": "^1.1.0"
5354
}
5455
}

0 commit comments

Comments
 (0)