mirror of
https://github.com/songquanpeng/one-api.git
synced 2026-03-04 02:34:25 +08:00
feat: add new theme berry (#860)
* feat: add theme berry * docs: add development notes * fix: fix blank page * chore: update implementation * fix: fix package.json * chore: update ui copy --------- Co-authored-by: JustSong <songquanpeng@foxmail.com>
This commit is contained in:
31
web/berry/src/index.js
Normal file
31
web/berry/src/index.js
Normal file
@@ -0,0 +1,31 @@
|
||||
import { createRoot } from 'react-dom/client';
|
||||
|
||||
// third party
|
||||
import { BrowserRouter } from 'react-router-dom';
|
||||
import { Provider } from 'react-redux';
|
||||
|
||||
// project imports
|
||||
import * as serviceWorker from 'serviceWorker';
|
||||
import App from 'App';
|
||||
import { store } from 'store';
|
||||
|
||||
// style + assets
|
||||
import 'assets/scss/style.scss';
|
||||
import config from './config';
|
||||
|
||||
// ==============================|| REACT DOM RENDER ||============================== //
|
||||
|
||||
const container = document.getElementById('root');
|
||||
const root = createRoot(container); // createRoot(container!) if you use TypeScript
|
||||
root.render(
|
||||
<Provider store={store}>
|
||||
<BrowserRouter basename={config.basename}>
|
||||
<App />
|
||||
</BrowserRouter>
|
||||
</Provider>
|
||||
);
|
||||
|
||||
// If you want your app to work offline and load faster, you can change
|
||||
// unregister() to register() below. Note this comes with some pitfalls.
|
||||
// Learn more about service workers: https://bit.ly/CRA-PWA
|
||||
serviceWorker.register();
|
||||
Reference in New Issue
Block a user