diff --git a/README.md b/README.md index 87ba6fe..a366665 100644 --- a/README.md +++ b/README.md @@ -6,14 +6,12 @@ > ❤️ **If you like this repository, [you can click here to tweet it and make it spread](https://ctt.ec/PHba4).** - ## 🤔 Why Awesome-Cheatsheets? -I always make a cheatsheet when I want to improve my skills on a programming language, a framework or a development tool. [I started doing these kind of things a long time ago on Gist](https://gist.github.com/LeCoupa) To better keep track of the history and to let people contribute to them, I reorganized everything into this single repository. Most of the content is coming from official documentations and some books I have read. +I always make a cheatsheet when I want to improve my skills on a programming language, a framework or a development tool. [I started doing these kind of things a long time ago on Gist](https://gist.github.com/LeCoupa) To better keep track of the history and to let people contribute to them, I reorganized everything into this single repository. Most of the content is coming from official documentations and some books I have read. Feel free to browse each cheatsheet to learn new things and to keep them at hand when you forgot about one command. They have been designed to provide a quick way to assess your knowledge and to save you time. - ## 📚 Table of Contents ### 📃 Languages @@ -32,8 +30,8 @@ Feel free to browse each cheatsheet to learn new things and to keep them at hand #### Functional * [JavaScript](languages/javascript.js) - + ### 📦 Backend @@ -49,8 +47,7 @@ Feel free to browse each cheatsheet to learn new things and to keep them at hand * [Feathers.js](backend/feathers.js) * [Moleculer](backend/moleculer.js) * [Node.js](backend/node.js) - - + ### 🌐 Frontend @@ -77,8 +74,7 @@ Feel free to browse each cheatsheet to learn new things and to keep them at hand #### NoSQL * [Redis](databases/redis.sh) - - + ### 🔧 Tools @@ -96,14 +92,12 @@ Feel free to browse each cheatsheet to learn new things and to keep them at hand * [Kubernetes](tools/kubernetes.sh) * [Nanobox Boxfile](tools/nanobox_boxfile.yml) * [Nanobox CLI](tools/nanobox_cli.sh) - - + ## 🙌🏼 How to Contribute? You are more than welcome to contribute and build your own cheatsheet for your favorite programming language, framework or development tool. Just submit changes via pull request and I will review them before merging. - ## 🙏🏻 Contribution @@ -120,6 +114,9 @@ You are more than welcome to contribute and build your own cheatsheet for your f +
+ +
diff --git a/frontend/html5.html b/frontend/html5.html index 24fd039..8dcf859 100644 --- a/frontend/html5.html +++ b/frontend/html5.html @@ -81,7 +81,7 @@ method="somefunction()" -enctype="" +enctype="" autocomplete="" novalidate accept-charset="" @@ -110,7 +110,7 @@ step="" name="" size="" -mupltiple +multiple required autofocus diff --git a/languages/javascript.js b/languages/javascript.js index fa7a5e2..932893e 100644 --- a/languages/javascript.js +++ b/languages/javascript.js @@ -1,9 +1,52 @@ +/* ******************************************************************************************* + * GLOBAL OBJECTS > OBJECT + * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object + * ******************************************************************************************* */ + +// Global object: properties +Object.length // length is a property of a function object, and indicates how many arguments the function expects, i.e. the number of formal parameters. This number does not include the rest parameter. Has a value of 1. +Object.prototype // Represents the Object prototype object and allows to add new properties and methods to all objects of type Object. + +// Methods of the Object constructor +Object.assign(target, ...sources) // Copies the values of all enumerable own properties from one or more source objects to a target object. method is used to copy the values of all enumerable own properties from one or more source objects to a target object. It will return the target object +Object.create(MyObject) // Creates a new object with the specified prototype object and properties. The object which should be the prototype of the newly-created object. +Object.defineProperty(obj, prop, descriptor) // Adds the named property described by a given descriptor to an object. +Object.defineProperties(obj, props) // Adds the named properties described by the given descriptors to an object. +Object.entries(obj) // Returns an array containing all of the [key, value] pairs of a given object's own enumerable string properties. +Object.freeze(obj) // Freezes an object: other code can't delete or change any properties. +Object.getOwnPropertyDescriptor(obj, prop) // Returns a property descriptor for a named property on an object. +Object.getOwnPropertyDescriptors(obj) // Returns an object containing all own property descriptors for an object. +Object.getOwnPropertyNames(obj) // Returns an array containing the names of all of the given object's own enumerable and non-enumerable properties. +Object.getOwnPropertySymbols(obj) // Returns an array of all symbol properties found directly upon a given object. +Object.getPrototypeOf(obj) // Returns the prototype of the specified object. +Object.is(value1, value2); // Compares if two values are the same value. Equates all NaN values (which differs from both Abstract Equality Comparison and Strict Equality Comparison). +Object.isExtensible(obj) // Determines if extending of an object is allowed. +Object.isFrozen(obj) // Determines if an object was frozen. +Object.isSealed(obj) // Determines if an object is sealed. +Object.keys(obj) // Returns an array containing the names of all of the given object's own enumerable string properties. +Object.preventExtensions(obj) // Prevents any extensions of an object. +Object.seal(obj) // Prevents other code from deleting properties of an object. +Object.setPrototypeOf(obj, prototype) // Sets the prototype (i.e., the internal [[Prototype]] property). +Object.values(obj) // Returns an array containing the values that correspond to all of a given object's own enumerable string properties. + +// Object instances and Object prototype object (Object.prototype.property or Object.prototype.method()) +// Properties +obj.constructor // Specifies the function that creates an object's prototype. +obj.__proto__ // Points to the object which was used as prototype when the object was instantiated. + +// Methods +obj.hasOwnProperty(prop) // Returns a boolean indicating whether an object contains the specified property as a direct property of that object and not inherited through the prototype chain. +prototypeObj.isPrototypeOf(object) // Returns a boolean indicating whether the object this method is called upon is in the prototype chain of the specified object. +obj.propertyIsEnumerable(prop) // Returns a boolean indicating if the internal ECMAScript [[Enumerable]] attribute is set. +obj.toLocaleString() // Calls toString(). +obj.toString() // Returns a string representation of the object. +object.valueOf() // Returns the primitive value of the specified object. + /* ******************************************************************************************* * GLOBAL OBJECTS > ARRAY * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array * ******************************************************************************************* */ - // Global object: properties Array.length // Reflects the number of elements in an array. Array.prototype // Represents the prototype for the Array constructor and allows to add new properties and methods to all Array objects.