seanchas116 / glob-loader Goto Github PK
View Code? Open in Web Editor NEWwebpack loader to load files at once with glob
License: MIT License
webpack loader to load files at once with glob
License: MIT License
the filename should be available as the key, with the value being the exported module (similar to require-dir)
Would be nice to have release tags on Github as well, preferably with something that mimics the changelog :)
I just finished tracking down the source of a very frustrating bug. You can find it replicated in this repo.
$ git clone https://github.com/tkambler/webpack-examples.git && cd webpack-examples/angular1
$ yarn
$ yarn run bundle-serve
Note the generated bundles in the dist
folder. Libs that are common amongst the bundles are correctly placed within the common.bundle.js
bundle.
Now do this:
$ rm -rf ./src/filters/src
$ yarn run bundle-serve
Now look at the bundles again. Common libs are no longer placed within the common.bundle.js
file. Each bundle contains duplicate copies of shared libs.
Not sure if I am using this wrong ..
require('glob-loader!/src/css/.css');
Module not found: Error: Cannot resolve 'file' or 'directory' ./src/css/.css
So I am trying to require any css file in the src/css folder the path for me is correct because I can manually copy a css file using file-loader using the same path i.e.
require('file?name=css/hacks.css!src/css/hacks.css'); //this works file by file so the path is right - TY
Hey, I'm trying to use your loader to convert an app to webpack
I need glob requiring until we get proper in file requiring of dependencies.
I run io.js 2.3.5 on linux (fedora) i try to do use it inline :
require("glob-loader!./modules//.js");
but it gives me the follwing error
Module not found: Error: Cannot resolve 'file' or 'directory' ./modules//.js in /home/nadavsinai/sites/startapp/portal/public
@ ./application.js 46:0-39
can you spot my problem?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.