Comments (4)
How about moving to specific lodash modules?
Instead of requireing whole underscore, we could just require necessary functions:
var _ = {
extend: require('lodash.extend'),
isRegExp: require('lodash.isregexp'),
isFunction: require('lodash.isfunction'),
result: require('lodash.result')
};
or
var _extend = require('lodash.extend');
var _isRegExp = require('lodash.isregexp');
var _isFunction = require('lodash.isfunction');
var _result = require('lodash.result');
or even leverage something like https://github.com/lukekarrys/lodash-replacer.
from ampersand-router.
The advantage of a single module is that it is easier to install; Browserify does only include the used files so the the end result should be the same.
lodash-replacer
looks interesting, but since it requires some effort to configure, most users probably won't use it and end up with the full underscore in their apps.
from ampersand-router.
lodash-cli looks really interesting, it can be used to generate a modular lodash build that puts each function in its own file and supports CommonJS.
from ampersand-router.
We will be tracking the removal of underscore here AmpersandJS/ampersand#36
from ampersand-router.
Related Issues (20)
- pushState should be true by default when starting history HOT 2
- {trigger: true} should be the default for history.navigate method.
- Trigger current route callback again HOT 9
- is a "catchAll" route impossible by design? HOT 1
- event binding fails while initialize new Router(options) HOT 4
- Incorrect routing of anchors when root is set HOT 3
- Document browser support
- Hash changes are impossible to follow HOT 3
- ampersand-router pulls in underscore HOT 4
- Extract History and Router into independent modules. HOT 1
- Question: no route change detection by default? HOT 1
- Basic readme example not cleaning up stuff? HOT 1
- Feature Request: make user navigation history exportable
- Last index in execute args is always null HOT 1
- encoded "%" gets stripped fragment in navigate call
- Non-root routes pass requests to server HOT 4
- Document history API HOT 1
- What about the order of the routes-property when JavaScript Object properties have no inherent order?
- add event after navigate
- search part of location is misinterpreted as fragment when root is not "/"
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ampersand-router.