Comments (6)
I'm not sure how import
vs require
makes usage of the package any different - the README already has an example of both modular and shimmed usage.
In general, examples for feature X shouldn't rely unnecessarily on feature Y - in this case, for..of
support.
from object.entries.
That's a point, but still i had to dig into the code to understand how things are working, wouldn't use Object.entries without an ES6 syntax, but that's more a personal preference. I think the ES6 example is more clear how Object.entries is useful as some assert.deepEqual(Object.entries(obj), expected);
. I never used this assert module, maybe i'm missing something out. Anyways, the example relies on this assert module, which is not needed to use Object.entries and therefore not a good and self explaining example in my opinion.
If we think about the future, ES6 will be the standard, why not give it a short example?
I'm using Object.entries only for [key, value], that was the reason i looked for this module, and maybe some others are doing this too. A self explaining example would be a good thing.
from object.entries.
Sure, PRs welcome.
Fwiw, assert is both a nice core module and common pseudocode throughout CS and every language to denote assertions.
from object.entries.
How do I use the 'auto.js' functionality? I don't want to add a bunch of code; that's what I'm trying to avoid by using a polyfill.
from object.entries.
@pabrams import 'object.entries/auto'
or require('object.entries/auto')
in your app's entry point is sufficient.
from object.entries.
Closing for now; happy to accept documentation PRs in the future.
from object.entries.
Related Issues (12)
- Not-yet-visited keys deleted on a [[Get]] must not show up in the output
- 30 KB of code added to distribution HOT 5
- Exclude test output from npm package HOT 1
- Question about implementation HOT 2
- too complex HOT 3
- Shim doesn't work on Chrome 49 HOT 4
- Action required: Greenkeeper could not be activated 🚨
- An in-range update of eslint is breaking the build 🚨 HOT 1
- An in-range update of es-abstract is breaking the build 🚨 HOT 1
- Dependency Dashboard
- Entries misspelled HOT 1
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 object.entries.