Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 0 additions & 30 deletions app/view/.umirc.js

This file was deleted.

3 changes: 0 additions & 3 deletions app/view/.umirc.ts

This file was deleted.

33 changes: 24 additions & 9 deletions app/view/index.html
Original file line number Diff line number Diff line change
@@ -1,10 +1,25 @@
<!DOCTYPE html>
<!doctype html>
<html>
<head>
<meta charset="UTF-8">
</head>
<body>
<div id="root" data-reactroot=""></div>
<script src="/umi.js"></script>
</body>
</html>
<head>
<meta charset="utf-8" />
<meta name="apple-mobile-web-app-capable" content="yes"/>
<meta name="apple-mobile-web-app-status-bar-style" content="black"/>
<meta name="format-detection" content="telephone=no"/>
<meta name="format-detection" content="email=no"/>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, minimum-scale=1, user-scalable=no" />
<title></title>
{{ helper.assets.getStyle('umi.css') | safe }}
</head>
<body>

<div id="root"></div>

<script>
window.routerBase = '/';
window.resourceBaseUrl = '{{ helper.assets.resourceBase }}';
window.publicPath = '{{ helper.assets.resourceBase }}';
</script>
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.data-set-0.9.6/dist/data-set.min.js"></script>
{{ helper.assets.getScript('umi.js') | safe }}
</body>
</html>
17 changes: 0 additions & 17 deletions app/view/package.json

This file was deleted.

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
14 changes: 14 additions & 0 deletions app/web/.umirc.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
// ref: https://umijs.org/config/
export default {
npmClient: 'npm',
routes: [
{
path: '/',
component: '../layouts/index',
routes: [
{ path: '/', component: '../pages/index' }
]
}
],
runtimePublicPath: {},
}
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
15 changes: 7 additions & 8 deletions config/config.default.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,23 +27,22 @@ module.exports = appInfo => {
dir: path.join(appInfo.baseDir, 'app/public'),
},
view: {
root: [
path.join(appInfo.baseDir, 'app/view'),
].join(','),
root: path.join(appInfo.baseDir, 'app/view'),
mapping: {
'.nj': 'nunjucks',
'.js': 'assets',
'.html': 'nunjucks',
},
defaultViewEngine: 'nunjucks',
},
assets: {
publicPath: '/public/',
devServer: {
debug: true,
command: 'cross-env REACT_APP_ENV=dev MOCK=none APP_ROOT=$PWD/app/view USE_WEBPACK_5=1 UMI_ENV=dev umi dev',
command: 'umi dev',
port: 8000,
env: {
APP_ROOT: path.join(__dirname, 'app/view'),
USE_WEBPACK_5: 1,
UMI_ENV: 'dev',
REACT_APP_ENV: 'devumi',
APP_ROOT: path.join(__dirname, '../app/web'),
BROWSER: 'none',
ESLINT: 'none',
SOCKET_SERVER: 'http://127.0.0.1:8000',
Expand Down