mirror of
https://github.com/tenrok/vue-ganttastic.git
synced 2026-06-24 16:20:33 +03:00
chore: webpack
This commit is contained in:
@@ -0,0 +1,9 @@
|
|||||||
|
root = true
|
||||||
|
|
||||||
|
[*]
|
||||||
|
charset = utf-8
|
||||||
|
indent_style = space
|
||||||
|
indent_size = 2
|
||||||
|
end_of_line = lf
|
||||||
|
insert_final_newline = true
|
||||||
|
trim_trailing_whitespace = true
|
||||||
+4
-13
@@ -1,21 +1,12 @@
|
|||||||
.DS_Store
|
.DS_Store
|
||||||
node_modules
|
node_modules/
|
||||||
/dist
|
dist/
|
||||||
|
npm-debug.log
|
||||||
# local env files
|
yarn-error.log
|
||||||
.env.local
|
|
||||||
.env.*.local
|
|
||||||
|
|
||||||
# Log files
|
|
||||||
npm-debug.log*
|
|
||||||
yarn-debug.log*
|
|
||||||
yarn-error.log*
|
|
||||||
|
|
||||||
# Editor directories and files
|
# Editor directories and files
|
||||||
.idea
|
.idea
|
||||||
.vscode
|
|
||||||
*.suo
|
*.suo
|
||||||
*.ntvs*
|
*.ntvs*
|
||||||
*.njsproj
|
*.njsproj
|
||||||
*.sln
|
*.sln
|
||||||
*.sw?
|
|
||||||
|
|||||||
-23
@@ -1,23 +0,0 @@
|
|||||||
.DS_Store
|
|
||||||
node_modules
|
|
||||||
/dist
|
|
||||||
src/Playground.vue
|
|
||||||
|
|
||||||
|
|
||||||
# local env files
|
|
||||||
.env.local
|
|
||||||
.env.*.local
|
|
||||||
|
|
||||||
# Log files
|
|
||||||
npm-debug.log*
|
|
||||||
yarn-debug.log*
|
|
||||||
yarn-error.log*
|
|
||||||
|
|
||||||
# Editor directories and files
|
|
||||||
.idea
|
|
||||||
.vscode
|
|
||||||
*.suo
|
|
||||||
*.ntvs*
|
|
||||||
*.njsproj
|
|
||||||
*.sln
|
|
||||||
*.sw?
|
|
||||||
@@ -122,7 +122,7 @@ Pull requests are warmly welcomed, while every major change or proposal ought to
|
|||||||
3. <code>Playground.vue</code> is a dedicated Vue SFC where all Vue-Ganttastic features can be
|
3. <code>Playground.vue</code> is a dedicated Vue SFC where all Vue-Ganttastic features can be
|
||||||
played around with and tested out. Get it running using:
|
played around with and tested out. Get it running using:
|
||||||
```
|
```
|
||||||
vue serve src/Playground.vue
|
npm run dev
|
||||||
```
|
```
|
||||||
|
|
||||||
## Dependencies
|
## Dependencies
|
||||||
|
|||||||
@@ -1,11 +0,0 @@
|
|||||||
module.exports = {
|
|
||||||
banner: true,
|
|
||||||
output: {
|
|
||||||
extractCSS: false,
|
|
||||||
},
|
|
||||||
plugins: {
|
|
||||||
vue: {
|
|
||||||
css: true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
};
|
|
||||||
+11
@@ -0,0 +1,11 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="en">
|
||||||
|
<head>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<title>vue-ganttastic</title>
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<div id="vue-ganttastic-825301a1"></div>
|
||||||
|
<script src="/dist/build.js"></script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
Generated
+13659
-8531
File diff suppressed because it is too large
Load Diff
+21
-9
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@tenrok/vue-ganttastic",
|
"name": "@tenrok/vue-ganttastic",
|
||||||
"version": "0.10.6",
|
"version": "0.10.7",
|
||||||
"description": "A simple and customizable Gantt chart component for Vue.js",
|
"description": "A simple and customizable Gantt chart component for Vue.js",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"gantt",
|
"gantt",
|
||||||
@@ -34,23 +34,35 @@
|
|||||||
"files": [
|
"files": [
|
||||||
"dist/*"
|
"dist/*"
|
||||||
],
|
],
|
||||||
"main": "./dist/index.js",
|
"main": "src/main.js",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "git+https://github.com/tenrok/vue-ganttastic.git"
|
"url": "git+https://github.com/tenrok/vue-ganttastic.git"
|
||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"test": "echo \"Error: no test specified\" && exit 1",
|
"dev": "cross-env NODE_ENV=development webpack-dev-server --open --hot",
|
||||||
"build": "bili --plugin.vue",
|
"build": "cross-env NODE_ENV=production webpack --progress --hide-modules"
|
||||||
"serve": "vue serve ./src/Playground.vue"
|
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"vue": "^2.6.14"
|
"vue": "^2.5.11"
|
||||||
},
|
},
|
||||||
|
"browserslist": [
|
||||||
|
"> 1%",
|
||||||
|
"last 2 versions",
|
||||||
|
"not ie <= 8"
|
||||||
|
],
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"bili": "^4.10.0",
|
"babel-core": "^6.26.0",
|
||||||
"rollup-plugin-vue": "^5.1.9",
|
"babel-loader": "^7.1.2",
|
||||||
"vue-template-compiler": "^2.6.14"
|
"babel-preset-env": "^1.6.0",
|
||||||
|
"babel-preset-stage-3": "^6.24.1",
|
||||||
|
"cross-env": "^5.0.5",
|
||||||
|
"css-loader": "^0.28.7",
|
||||||
|
"file-loader": "^1.1.4",
|
||||||
|
"vue-loader": "^13.0.5",
|
||||||
|
"vue-template-compiler": "^2.4.4",
|
||||||
|
"webpack": "^3.6.0",
|
||||||
|
"webpack-dev-server": "^2.9.1"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"moment": "^2.26.0"
|
"moment": "^2.26.0"
|
||||||
|
|||||||
@@ -39,6 +39,7 @@ import GGanttChart from './GGanttChart.vue'
|
|||||||
import GGanttRow from './GGanttRow.vue'
|
import GGanttRow from './GGanttRow.vue'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
name: 'playground',
|
||||||
components: {
|
components: {
|
||||||
GGanttChart,
|
GGanttChart,
|
||||||
GGanttRow,
|
GGanttRow,
|
||||||
|
|||||||
@@ -1,4 +0,0 @@
|
|||||||
import GGanttChart from './GGanttChart.vue'
|
|
||||||
import GGanttRow from './GGanttRow.vue'
|
|
||||||
|
|
||||||
export { GGanttChart, GGanttRow }
|
|
||||||
+18
@@ -0,0 +1,18 @@
|
|||||||
|
import Vue from 'vue'
|
||||||
|
import GGanttChart from './GGanttChart.vue'
|
||||||
|
import GGanttRow from './GGanttRow.vue'
|
||||||
|
import Playground from './Playground.vue'
|
||||||
|
|
||||||
|
let uniqId = '#vue-ganttastic-825301a1'
|
||||||
|
|
||||||
|
if (document.querySelector(uniqId)) {
|
||||||
|
Vue.component('GGanttChart', GGanttChart)
|
||||||
|
Vue.component('GGanttRow', GGanttRow)
|
||||||
|
|
||||||
|
new Vue({
|
||||||
|
el: uniqId,
|
||||||
|
render: (h) => h(Playground),
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export { GGanttRow, GGanttChart }
|
||||||
@@ -0,0 +1,78 @@
|
|||||||
|
var path = require('path')
|
||||||
|
var webpack = require('webpack')
|
||||||
|
|
||||||
|
module.exports = {
|
||||||
|
entry: './src/main.js',
|
||||||
|
output: {
|
||||||
|
path: path.resolve(__dirname, './dist'),
|
||||||
|
publicPath: '/dist/',
|
||||||
|
filename: 'build.js'
|
||||||
|
},
|
||||||
|
module: {
|
||||||
|
rules: [
|
||||||
|
{
|
||||||
|
test: /\.css$/,
|
||||||
|
use: [
|
||||||
|
'vue-style-loader',
|
||||||
|
'css-loader'
|
||||||
|
],
|
||||||
|
}, {
|
||||||
|
test: /\.vue$/,
|
||||||
|
loader: 'vue-loader',
|
||||||
|
options: {
|
||||||
|
loaders: {
|
||||||
|
}
|
||||||
|
// other vue-loader options go here
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
test: /\.js$/,
|
||||||
|
loader: 'babel-loader',
|
||||||
|
exclude: /node_modules/
|
||||||
|
},
|
||||||
|
{
|
||||||
|
test: /\.(png|jpg|gif|svg)$/,
|
||||||
|
loader: 'file-loader',
|
||||||
|
options: {
|
||||||
|
name: '[name].[ext]?[hash]'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
resolve: {
|
||||||
|
alias: {
|
||||||
|
'vue$': 'vue/dist/vue.esm.js'
|
||||||
|
},
|
||||||
|
extensions: ['*', '.js', '.vue', '.json']
|
||||||
|
},
|
||||||
|
devServer: {
|
||||||
|
historyApiFallback: true,
|
||||||
|
noInfo: true,
|
||||||
|
overlay: true
|
||||||
|
},
|
||||||
|
performance: {
|
||||||
|
hints: false
|
||||||
|
},
|
||||||
|
devtool: '#eval-source-map'
|
||||||
|
}
|
||||||
|
|
||||||
|
if (process.env.NODE_ENV === 'production') {
|
||||||
|
module.exports.devtool = '#source-map'
|
||||||
|
// http://vue-loader.vuejs.org/en/workflow/production.html
|
||||||
|
module.exports.plugins = (module.exports.plugins || []).concat([
|
||||||
|
new webpack.DefinePlugin({
|
||||||
|
'process.env': {
|
||||||
|
NODE_ENV: '"production"'
|
||||||
|
}
|
||||||
|
}),
|
||||||
|
new webpack.optimize.UglifyJsPlugin({
|
||||||
|
sourceMap: true,
|
||||||
|
compress: {
|
||||||
|
warnings: false
|
||||||
|
}
|
||||||
|
}),
|
||||||
|
new webpack.LoaderOptionsPlugin({
|
||||||
|
minimize: true
|
||||||
|
})
|
||||||
|
])
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user