Comments (5)
Thought this might come in handy. This what's currently in use of underscore (in /src dir):
$ grep -rhoe '_\.[^(]\+' . | sort | uniq
_.after
_.all
_.any
_.bind
_.clone
_.debounce
_.each
_.isArray
_.isEqual
_.isFunction
_.isNaN
_.isObject
_.isString
_.throttle
_.without
Btw, a custom Lo-Dash build might be an option.
from postal.js.
@webpro Thanks - you saved me a lot of trouble! :-) I've been considering a few different options going forward, since we're about to make another pass over the API and try to normalize some things between channel def and top level pub/sub calls. Among the options I'm pondering:
- With regards to dependencies:
- non underscore/lodash build using shims if it significantly reduces footprint.
- custom underscore or lodash build containing only the pieces postal utilizes
- leaving things as they are
- With regards to modularity/build customizations
- any shims/custom underscore/lodash builds would ideally be swappable (i.e. - why carry the extra weight of the shims if the project is already using underscore for other needs?)
- separate some of the additional features on the SubscriptionDefinition prototype into an add-on, so that you could opt-in to the fluent calls like "withDebounce", etc. by including that add-on (or using a postal build that has it included already)
- Whatever & however we decide to break things up - my intent is to always provide a simple "everything" build of postal, with the custom builds for more advanced/targeted situations.
Anyway - just thought I'd explain more of what I'm thinking along these lines. Sounds like you may have predicted some of that as well :)
from postal.js.
On a related topic, it seems that the native (ECMA-262 ), underscore and lo-dash forEach method behave different when dealing with arrays that contain elements that are undefined. IE8<= also behaves different than the other browsers.
from postal.js.
The new Lodash release gives you lots of options for trimming down the lib size. You might want to take a look at that:
http://kitcambridge.be/blog/custom-builds-in-lo-dash-2-dot-0/
from postal.js.
Closing this out. Lodash has replaced underscore since v0.9 (IIRC), and future work may explore custom builds of lodash or ES6 builds...
from postal.js.
Related Issues (20)
- How to publish data between Node.js modules? HOT 2
- Bower Release v2.0.5
- Competing consumers HOT 1
- Help improve the quality of the DefinitelyTyped (TypeScript) definitions
- postal.preserve: Still taking a ConduitJS dependency HOT 2
- Default Subscriber
- Stack overflow in IE 11 when publish called on channel with many pending unsubscribes
- Shouldn't postal.channel() implement the Singleton pattern? HOT 2
- Subscriber callback method can brake calling other subscribers HOT 1
- Devtools extension for Chrome
- Messages published inside a subscriber won't be passed to uncached subscribers
- why cache only for result === true
- postal.lodash.js Error: Module name "lodash/after" has not been loaded
- Is this project still active? HOT 6
- Wait for messages to be delivered and processed in unit tests
- timeStamp in envelope should honor timezone
- Timestamp missing on wireTap envelopes
- Thank you
- Regarding publish and subscribe, Important question
- How does postal.js support replay?
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 postal.js.