Skip to content

Commit 90a0d6f

Browse files
committed
Rename /example to /docs
1 parent eef9be3 commit 90a0d6f

14 files changed

+16
-16
lines changed

dist/vuejs-dialog.min.js

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/vuejs-dialog.min.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
File renamed without changes.

example/app.main.js docs/app.main.js

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

example/index.html docs/index.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@
33
<head>
44
<meta charset="UTF-8">
55
<title>VueJs Plugin usage example</title>
6-
<link href="app.main.css?11ee61d2c63f5bd8ebbf" rel="stylesheet"></head>
6+
<link href="app.main.css?b5f8901847967c64b6a0" rel="stylesheet"></head>
77
<body>
88
<div id="app"></div>
99

1010
<script src="https://unpkg.com/vue@2.4.2/dist/vue.min.js"></script>
1111
<script type="text/javascript" src="../dist/vuejs-dialog.min.js"></script>
12-
<script type="text/javascript" src="app.main.js?11ee61d2c63f5bd8ebbf"></script></body>
12+
<script type="text/javascript" src="app.main.js?b5f8901847967c64b6a0"></script></body>
1313
</html>
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

src/example/js/translations.js src/docs/js/translations.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import en from './translations/en'
44

55

66
const Translator = function(translations, separator = '.'){
7-
let lang = window.navigator.languages[1]
7+
let lang = window.navigator.languages[1] || window.navigator.userLanguage[1]
88
this.lang = typeof translations[lang] !== 'undefined' ? lang : 'en'
99
this.separator = '.'
1010
this.translations = translations
File renamed without changes.
File renamed without changes.

webpack.config.js

+10-10
Original file line numberDiff line numberDiff line change
@@ -70,18 +70,18 @@ const COMMON = {
7070
devtool: '#eval-source-map'
7171
}
7272

73-
const EXAMPLE = Object.assign({}, COMMON, {
74-
name: 'example',
73+
const DOCS = Object.assign({}, COMMON, {
74+
name: 'docs',
7575
entry: [
76-
'./src/example/js/app.js',
77-
'./src/example/scss/app.scss'
76+
'./src/docs/js/app.js',
77+
'./src/docs/scss/app.scss'
7878
],
7979
output: {
80-
path: path.resolve(__dirname, './example'),
80+
path: path.resolve(__dirname, './docs'),
8181
filename: "app.[name].js",
8282
},
8383
devServer: {
84-
contentBase: path.join(__dirname, "example"),
84+
contentBase: path.join(__dirname, "docs"),
8585
compress: true,
8686
port: 9000
8787
},
@@ -95,7 +95,7 @@ const EXAMPLE = Object.assign({}, COMMON, {
9595
hash: true,
9696
catch: true,
9797
filename: 'index.html',
98-
template: 'src/example/index.html'
98+
template: 'src/docs/index.html'
9999
})
100100
]
101101
})
@@ -132,8 +132,8 @@ if (isProduction) {
132132
})
133133
])
134134

135-
EXAMPLE.devtool = '#none'
136-
EXAMPLE.plugins = (EXAMPLE.plugins || []).concat([
135+
DOCS.devtool = '#none'
136+
DOCS.plugins = (DOCS.plugins || []).concat([
137137
new webpack.DefinePlugin({
138138
'process.env': {
139139
NODE_ENV: '"production"'
@@ -148,4 +148,4 @@ if (isProduction) {
148148
])
149149
}
150150

151-
module.exports = [EXAMPLE, DIST]
151+
module.exports = [DOCS, DIST]

0 commit comments

Comments
 (0)