javascript - Waypoint npm - Error: Can't resolve 'waypoint -
i have vue project , installed waypoints
npm install waypoints
i try import
import waypoint 'waypoints';
but error
error: can't resolve 'waypoints' in /mypath
what doing wrong?
var webpack = require('webpack'); var path = require('path'); let extracttextplugin = require("extract-text-webpack-plugin"); var webpacknotifierplugin = require('webpack-notifier'); var fs = require('file-system'); var cleanwebpackplugin = require('clean-webpack-plugin'); module.exports = { /*node: { fs: "empty" },*/ resolve: { alias: { 'masonry': 'masonry-layout', 'isotope': 'isotope-layout' } }, entry: './main.js', devtool: 'source-map', output: { path: path.resolve(__dirname, './public/assets'), filename: 'bundle.[chunkhash].js', }, module: { rules: [ { test: /\.js$/, exclude: /node_modules/, loader: "babel-loader?presets[]=es2015", }, { test:/\.scss$/, use: extracttextplugin.extract({ use: [{loader:'css-loader?sourcemap'}, {loader:'sass-loader', options: { sourcemap: true, }}], }) }, { test: /\.vue$/, loader: 'vue-loader', options: { loaders: { } // other vue-loader options go here } }, ] }, plugins: [ new cleanwebpackplugin(['assets/*', 'css/*'], { root: '/users/leith/sites/laravelleith/public', verbose: true, dry: false, exclude: ['360lockturret.jpg'], watch: true }), new webpack.optimize.uglifyjsplugin(), new extracttextplugin('app.[chunkhash].css'), new webpacknotifierplugin(), function() { this.plugin('done', stats =>{ fs.writefilesync( path.join(__dirname, 'manifest.json'), json.stringify(stats.tojson().assetsbychunkname) ) }); } ] };
Comments
Post a Comment