Git Product home page Git Product logo

javascript's People

Contributors

bocharsky-bw avatar ioni14 avatar knpudinobot avatar leannapelham avatar mollokhan avatar sadikoff avatar stof avatar weaverryan avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

javascript's Issues

The description of the Set object is totally wrong currently

I'm talking about this chapter: knpuniversity.com/screencast/javascript-es6/set-object

currently, the description looks like this:

The Map object is perfect for maps, or associative arrays as we call them in the PHP biz. ES2015 gives us another object called Set. This new fancy object replaces using true, indexed arrays.
// ...
ep - the Set object is just like an array, but with some helper methods! Back up in loadRepLogs, after the for loop, let's see how this looks: console.log(this.repLogs). Oh, and let's also use one of its helper methods: this.repLogs.has(data.items[0]). Obviously, this item should have been added to the Set!

This description is wrong. Set and Array are totally different data structures:

  • Array is the ES representation of a sequence (and btw, it is an object with helper methods. you might like Array.prototype.includes in ES2016 for the example used in your current description)
  • Set is the ES representation of ... a set, i.e. a data structure ensuring uniqueness of values in it.

The case of repLogs is a use case for Array, not for Set.

The article about Map should mention the entries function

When you need both keys and values during the iteration over a Map, there is an easy way to do it with for of:

for (let [key, value] of myMap.entries()) {
// do something
}

This is much better than using for in, which is looping over iterable properties of the Map object (which won't do what you expect here).

Btw, Array has this method too in ES2015, in case you need to access both the value and the integer index (requires a polyfill for IE, of course).

Array, Map and Set are big friends in ES2015.

Registration functionality is not working.

On production enviroment i get this:

Oops! An Error Occurred
The server returned a "500 Internal Server Error".
Something is broken. Please let us know what you were doing when this error occurred. We will fix it as soon as possible. Sorry for any inconvenience caused.

On development enviroment i get this:

Class "fos_user.model.user.class" not found. Is the "data_class" form option set correctly?
500 Internal Server Error - InvalidArgumentException

Any comments ?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.