Skip to content

Commit

Permalink
add docs for ember 6.0
Browse files Browse the repository at this point in the history
  • Loading branch information
mansona committed Dec 16, 2024
1 parent e980908 commit 5bafb5d
Show file tree
Hide file tree
Showing 162 changed files with 64,755 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
{
"data": {
"id": "ember-6.0.1-@ember/application",
"type": "class",
"attributes": {
"name": "@ember/application",
"shortname": "@ember/application",
"classitems": [],
"plugins": [],
"extensions": [],
"plugin_for": [],
"extension_for": [],
"module": "@ember/application",
"namespace": "",
"methods": [
{
"file": "packages/@ember/application/lib/lazy_load.ts",
"line": 14,
"description": "Detects when a specific package of Ember (e.g. 'Application')\nhas fully loaded and is available for extension.\n\nThe provided `callback` will be called with the `name` passed\nresolved from a string into the object:\n\n``` javascript\nimport { onLoad } from '@ember/application';\n\nonLoad('Ember.Application' function(hbars) {\n hbars.registerHelper(...);\n});\n```",
"itemtype": "method",
"name": "onLoad",
"static": 1,
"params": [
{
"name": "name",
"description": "name of hook",
"type": "String"
},
{
"name": "callback",
"description": "callback to be called",
"type": "Function"
}
],
"access": "private",
"tagname": "",
"class": "@ember/application",
"module": "@ember/application"
},
{
"file": "packages/@ember/application/lib/lazy_load.ts",
"line": 47,
"description": "Called when an Ember.js package (e.g Application) has finished\nloading. Triggers any callbacks registered for this event.",
"itemtype": "method",
"name": "runLoadHooks",
"static": 1,
"params": [
{
"name": "name",
"description": "name of hook",
"type": "String"
},
{
"name": "object",
"description": "object to pass to callbacks",
"type": "Object"
}
],
"access": "private",
"tagname": "",
"class": "@ember/application",
"module": "@ember/application"
}
],
"events": [],
"properties": []
},
"relationships": {
"parent-class": {
"data": null
},
"descendants": {
"data": []
},
"module": {
"data": {
"id": "ember-6.0.1-@ember/application",
"type": "module"
}
},
"project-version": {
"data": {
"id": "ember-6.0.1",
"type": "project-version"
}
}
}
}
}
189 changes: 189 additions & 0 deletions json-docs/ember/6.0.1/classes/ember-6.0.1-%40ember%2Farray.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,189 @@
{
"data": {
"id": "ember-6.0.1-@ember/array",
"type": "class",
"attributes": {
"name": "@ember/array",
"shortname": "@ember/array",
"classitems": [],
"plugins": [],
"extensions": [],
"plugin_for": [],
"extension_for": [],
"module": "ember",
"namespace": "",
"methods": [
{
"file": "packages/@ember/array/lib/make-array.ts",
"line": 5,
"description": "Forces the passed object to be part of an array. If the object is already\nan array, it will return the object. Otherwise, it will add the object to\nan array. If object is `null` or `undefined`, it will return an empty array.\n\n```javascript\nimport { makeArray } from '@ember/array';\nimport ArrayProxy from '@ember/array/proxy';\n\nmakeArray(); // []\nmakeArray(null); // []\nmakeArray(undefined); // []\nmakeArray('lindsay'); // ['lindsay']\nmakeArray([1, 2, 42]); // [1, 2, 42]\n\nlet proxy = ArrayProxy.create({ content: [] });\n\nmakeArray(proxy) === proxy; // false\n```",
"itemtype": "method",
"name": "makeArray",
"static": 1,
"params": [
{
"name": "obj",
"description": "the object",
"type": "Object"
}
],
"return": {
"description": "",
"type": "Array"
},
"access": "private",
"tagname": "",
"class": "@ember/array",
"module": "@ember/array"
},
{
"file": "packages/@ember/array/index.ts",
"line": 139,
"description": "Returns true if the passed object is an array or Array-like.\n\nObjects are considered Array-like if any of the following are true:\n\n - the object is a native Array\n - the object has an objectAt property\n - the object is an Object, and has a length property\n\nUnlike `typeOf` this method returns true even if the passed object is\nnot formally an array but appears to be array-like (i.e. implements `Array`)\n\n```javascript\nimport { isArray } from '@ember/array';\nimport ArrayProxy from '@ember/array/proxy';\n\nisArray(); // false\nisArray([]); // true\nisArray(ArrayProxy.create({ content: [] })); // true\n```",
"itemtype": "method",
"name": "isArray",
"static": 1,
"params": [
{
"name": "obj",
"description": "The object to test",
"type": "Object"
}
],
"return": {
"description": "true if the passed object is an array or Array-like",
"type": "Boolean"
},
"access": "public",
"tagname": "",
"class": "@ember/array",
"module": "@ember/array"
},
{
"file": "packages/@ember/array/index.ts",
"line": 1858,
"description": "Creates an `Ember.NativeArray` from an Array-like object.\nDoes not modify the original object's contents.\n\nExample\n\n```js {data-filename=app/components/my-component.js}\nimport Component from '@ember/component';\nimport { A } from '@ember/array';\n\nexport default Component.extend({\n tagName: 'ul',\n classNames: ['pagination'],\n\n init() {\n this._super(...arguments);\n\n if (!this.get('content')) {\n this.set('content', A());\n this.set('otherContent', A([1,2,3]));\n }\n }\n});\n```",
"itemtype": "method",
"name": "A",
"static": 1,
"return": {
"description": "",
"type": "Ember.NativeArray"
},
"access": "public",
"tagname": "",
"class": "@ember/array",
"module": "@ember/array"
},
{
"file": "packages/@ember/array/index.ts",
"line": 1973,
"description": "Remove all occurrences of an object in the array.\n\n```javascript\nlet cities = ['Chicago', 'Berlin', 'Lima', 'Chicago'];\n\ncities.removeObject('Chicago'); // ['Berlin', 'Lima']\ncities.removeObject('Lima'); // ['Berlin']\ncities.removeObject('Tokyo') // ['Berlin']\n```",
"itemtype": "method",
"name": "removeObject",
"params": [
{
"name": "obj",
"description": "object to remove",
"type": "*"
}
],
"return": {
"description": "receiver",
"type": "EmberArray"
},
"access": "public",
"tagname": "",
"class": "@ember/array",
"module": "ember"
},
{
"file": "packages/@ember/array/index.ts",
"line": 1994,
"description": "Push the object onto the end of the array if it is not already\npresent in the array.\n\n```javascript\nlet cities = ['Chicago', 'Berlin'];\n\ncities.addObject('Lima'); // ['Chicago', 'Berlin', 'Lima']\ncities.addObject('Berlin'); // ['Chicago', 'Berlin', 'Lima']\n```",
"itemtype": "method",
"name": "addObject",
"params": [
{
"name": "obj",
"description": "object to add, if not already present",
"type": "*"
}
],
"return": {
"description": "receiver",
"type": "EmberArray"
},
"access": "public",
"tagname": "",
"class": "@ember/array",
"module": "ember"
},
{
"file": "packages/@ember/array/index.ts",
"line": 2015,
"description": "Sets the value on the named property for each member. This is more\nergonomic than using other methods defined on this helper. If the object\nimplements Observable, the value will be changed to `set(),` otherwise\nit will be set directly. `null` objects are skipped.\n\n```javascript\nlet people = [{name: 'Joe'}, {name: 'Matt'}];\n\npeople.setEach('zipCode', '10011');\n// [{name: 'Joe', zipCode: '10011'}, {name: 'Matt', zipCode: '10011'}];\n```",
"itemtype": "method",
"name": "setEach",
"params": [
{
"name": "key",
"description": "The key to set",
"type": "String"
},
{
"name": "value",
"description": "The object to set",
"type": "Object"
}
],
"return": {
"description": "receiver",
"type": "Object"
},
"access": "public",
"tagname": "",
"class": "@ember/array",
"module": "ember"
}
],
"events": [],
"properties": [
{
"file": "packages/@ember/array/index.ts",
"line": 2035,
"description": "This is the handler for the special array content property. If you get\nthis property, it will return this. If you set this property to a new\narray, it will replace the current content.\n\n```javascript\nlet peopleToMoon = ['Armstrong', 'Aldrin'];\n\npeopleToMoon.get('[]'); // ['Armstrong', 'Aldrin']\n\npeopleToMoon.set('[]', ['Collins']); // ['Collins']\npeopleToMoon.get('[]'); // ['Collins']\n```",
"itemtype": "property",
"name": "[]",
"return": {
"description": "this"
},
"access": "public",
"tagname": "",
"class": "@ember/array",
"module": "ember"
}
]
},
"relationships": {
"parent-class": {
"data": null
},
"descendants": {
"data": []
},
"module": {
"data": {
"id": "ember-6.0.1-ember",
"type": "module"
}
},
"project-version": {
"data": {
"id": "ember-6.0.1",
"type": "project-version"
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
{
"data": {
"id": "ember-6.0.1-@ember/component/helper",
"type": "class",
"attributes": {
"name": "@ember/component/helper",
"shortname": "@ember/component/helper",
"classitems": [],
"plugins": [],
"extensions": [],
"plugin_for": [],
"extension_for": [],
"module": "@ember/component",
"namespace": "",
"methods": [
{
"file": "packages/@ember/-internals/glimmer/lib/helper.ts",
"line": 333,
"description": "In many cases it is not necessary to use the full `Helper` class.\nThe `helper` method create pure-function helpers without instances.\nFor example:\n\n```js {data-filename=app/helpers/format-currency.js}\nimport { helper } from '@ember/component/helper';\n\nexport default helper(function([cents], {currency}) {\n return `${currency}${cents * 0.01}`;\n});\n```",
"static": 1,
"params": [
{
"name": "helper",
"description": "The helper function",
"type": "Function"
}
],
"itemtype": "method",
"name": "helper",
"access": "public",
"tagname": "",
"since": "1.13.0",
"class": "@ember/component/helper",
"module": "@ember/component"
}
],
"events": [],
"properties": []
},
"relationships": {
"parent-class": {
"data": null
},
"descendants": {
"data": []
},
"module": {
"data": {
"id": "ember-6.0.1-@ember/component",
"type": "module"
}
},
"project-version": {
"data": {
"id": "ember-6.0.1",
"type": "project-version"
}
}
}
}
}
Loading

0 comments on commit 5bafb5d

Please sign in to comment.