修改编译后访问路径

pull/1/head
Doflatango 2017-02-09 12:11:29 +08:00 committed by miraclesu
parent f8f857a184
commit 87ffb0be9e
4 changed files with 9 additions and 7 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -3,6 +3,7 @@
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<title>Cronsun Managerment</title> <title>Cronsun Managerment</title>
<base href='http://127.0.0.1:7079/ui/'</base>
<style> <style>
.loader, .loader:after {border-radius: 50%; width: 10em; height: 10em;} .loader, .loader:after {border-radius: 50%; width: 10em; height: 10em;}
.loader { .loader {
@ -34,6 +35,6 @@
<div id="app"> <div id="app">
<div class="loader"></div> <div class="loader"></div>
</div> </div>
<script src="/dist/build.js"></script> <script src="/ui/dist/build.js"></script>
</body> </body>
</html> </html>

View File

@ -5,7 +5,7 @@ module.exports = {
entry: './src/main.js', entry: './src/main.js',
output: { output: {
path: path.resolve(__dirname, './dist'), path: path.resolve(__dirname, './dist'),
publicPath: '/dist/', publicPath: '/',
filename: 'build.js' filename: 'build.js'
}, },
module: { module: {
@ -33,7 +33,8 @@ module.exports = {
test: /\.(png|jpg|gif|svg|ttf|woff|woff2|eot)\w*/, test: /\.(png|jpg|gif|svg|ttf|woff|woff2|eot)\w*/,
loader: 'file-loader', loader: 'file-loader',
options: { options: {
name: '[name].[ext]?[hash]' name: '[name].[ext]?[hash]',
publicPath: '/ui/dist/'
} }
}, },
{ {