@ngrx/entity 11.0.0-rc.0 → 11.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/ngrx-entity.umd.js +39 -637
- package/bundles/ngrx-entity.umd.js.map +1 -1
- package/bundles/ngrx-entity.umd.min.js +1 -1
- package/bundles/ngrx-entity.umd.min.js.map +1 -1
- package/esm2015/index.js +2 -7
- package/esm2015/ngrx-entity.js +2 -7
- package/esm2015/public_api.js +2 -7
- package/esm2015/src/create_adapter.js +2 -19
- package/esm2015/src/entity_state.js +1 -18
- package/esm2015/src/index.js +1 -6
- package/esm2015/src/models.js +1 -245
- package/esm2015/src/sorted_state_adapter.js +11 -139
- package/esm2015/src/state_adapter.js +9 -31
- package/esm2015/src/state_selectors.js +5 -43
- package/esm2015/src/unsorted_state_adapter.js +11 -151
- package/esm2015/src/utils.js +1 -13
- package/fesm2015/ngrx-entity.js +37 -668
- package/fesm2015/ngrx-entity.js.map +1 -1
- package/package.json +3 -3
- package/schematics-core/index.js +4 -1
- package/schematics-core/index.js.map +1 -1
- package/schematics-core/utility/ast-utils.js +127 -1
- package/schematics-core/utility/ast-utils.js.map +1 -1
- package/schematics-core/utility/config.js +1 -1
- package/schematics-core/utility/config.js.map +1 -1
- package/schematics-core/utility/find-component.js +101 -0
- package/schematics-core/utility/find-component.js.map +1 -0
- package/schematics-core/utility/libs-version.js +1 -1
- package/schematics-core/utility/libs-version.js.map +1 -1
- package/schematics-core/utility/project.js +4 -2
- package/schematics-core/utility/project.js.map +1 -1
- package/CHANGELOG.md +0 -3
- package/esm2015/index.ngsummary.json +0 -1
- package/esm2015/ngrx-entity.ngsummary.json +0 -1
- package/esm2015/public_api.ngsummary.json +0 -1
- package/esm2015/src/create_adapter.ngsummary.json +0 -1
- package/esm2015/src/entity_state.ngsummary.json +0 -1
- package/esm2015/src/index.ngsummary.json +0 -1
- package/esm2015/src/models.ngsummary.json +0 -1
- package/esm2015/src/sorted_state_adapter.ngsummary.json +0 -1
- package/esm2015/src/state_adapter.ngsummary.json +0 -1
- package/esm2015/src/state_selectors.ngsummary.json +0 -1
- package/esm2015/src/unsorted_state_adapter.ngsummary.json +0 -1
- package/esm2015/src/utils.ngsummary.json +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.js","sourceRoot":"","sources":["../../../../../modules/entity/schematics-core/utility/config.ts"],"names":[],"mappings":";;;AAAA,yDAAuE;
|
|
1
|
+
{"version":3,"file":"config.js","sourceRoot":"","sources":["../../../../../modules/entity/schematics-core/utility/config.ts"],"names":[],"mappings":";;;AAAA,yDAAuE;AAkIvE,SAAgB,gBAAgB,CAAC,IAAU;IACzC,IAAM,aAAa,GAAG,CAAC,eAAe,EAAE,gBAAgB,EAAE,iBAAiB,CAAC,CAAC;IAC7E,IAAM,IAAI,GAAG,aAAa,CAAC,MAAM,CAAC,UAAC,IAAI,IAAK,OAAA,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,EAAjB,CAAiB,CAAC,CAAC,CAAC,CAAC,CAAC;IAElE,OAAO,IAAI,CAAC;AACd,CAAC;AALD,4CAKC;AAED,SAAgB,YAAY,CAAC,IAAU;IACrC,IAAM,IAAI,GAAG,gBAAgB,CAAC,IAAI,CAAC,CAAC;IACpC,IAAM,YAAY,GAAG,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACrC,IAAI,YAAY,KAAK,IAAI,EAAE;QACzB,MAAM,IAAI,gCAAmB,CAAC,qBAAmB,IAAI,MAAG,CAAC,CAAC;KAC3D;IACD,IAAM,MAAM,GAAG,YAAY,CAAC,QAAQ,EAAE,CAAC;IAEvC,OAAO,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;AAC5B,CAAC;AATD,oCASC","sourcesContent":["import { SchematicsException, Tree } from '@angular-devkit/schematics';\n\n// The interfaces below are generated from the Angular CLI configuration schema\n// https://github.com/angular/angular-cli/blob/master/packages/@angular/cli/lib/config/schema.json\nexport interface AppConfig {\n /**\n * Name of the app.\n */\n name?: string;\n /**\n * Directory where app files are placed.\n */\n appRoot?: string;\n /**\n * The root directory of the app.\n */\n root?: string;\n /**\n * The output directory for build results.\n */\n outDir?: string;\n /**\n * List of application assets.\n */\n assets?: (\n | string\n | {\n /**\n * The pattern to match.\n */\n glob?: string;\n /**\n * The dir to search within.\n */\n input?: string;\n /**\n * The output path (relative to the outDir).\n */\n output?: string;\n }\n )[];\n /**\n * URL where files will be deployed.\n */\n deployUrl?: string;\n /**\n * Base url for the application being built.\n */\n baseHref?: string;\n /**\n * The runtime platform of the app.\n */\n platform?: 'browser' | 'server';\n /**\n * The name of the start HTML file.\n */\n index?: string;\n /**\n * The name of the main entry-point file.\n */\n main?: string;\n /**\n * The name of the polyfills file.\n */\n polyfills?: string;\n /**\n * The name of the test entry-point file.\n */\n test?: string;\n /**\n * The name of the TypeScript configuration file.\n */\n tsconfig?: string;\n /**\n * The name of the TypeScript configuration file for unit tests.\n */\n testTsconfig?: string;\n /**\n * The prefix to apply to generated selectors.\n */\n prefix?: string;\n /**\n * Experimental support for a service worker from @angular/service-worker.\n */\n serviceWorker?: boolean;\n /**\n * Global styles to be included in the build.\n */\n styles?: (\n | string\n | {\n input?: string;\n [name: string]: any; // tslint:disable-line:no-any\n }\n )[];\n /**\n * Options to pass to style preprocessors\n */\n stylePreprocessorOptions?: {\n /**\n * Paths to include. Paths will be resolved to project root.\n */\n includePaths?: string[];\n };\n /**\n * Global scripts to be included in the build.\n */\n scripts?: (\n | string\n | {\n input: string;\n [name: string]: any; // tslint:disable-line:no-any\n }\n )[];\n /**\n * Source file for environment config.\n */\n environmentSource?: string;\n /**\n * Name and corresponding file for environment config.\n */\n environments?: {\n [name: string]: any; // tslint:disable-line:no-any\n };\n appShell?: {\n app: string;\n route: string;\n };\n}\n\nexport function getWorkspacePath(host: Tree): string {\n const possibleFiles = ['/angular.json', '/.angular.json', '/workspace.json'];\n const path = possibleFiles.filter((path) => host.exists(path))[0];\n\n return path;\n}\n\nexport function getWorkspace(host: Tree) {\n const path = getWorkspacePath(host);\n const configBuffer = host.read(path);\n if (configBuffer === null) {\n throw new SchematicsException(`Could not find (${path})`);\n }\n const config = configBuffer.toString();\n\n return JSON.parse(config);\n}\n"]}
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
exports.__esModule = true;
|
|
3
|
+
exports.buildRelativePath = exports.findComponent = exports.findComponentFromOptions = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* @license
|
|
6
|
+
* Copyright Google Inc. All Rights Reserved.
|
|
7
|
+
*
|
|
8
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
9
|
+
* found in the LICENSE file at https://angular.io/license
|
|
10
|
+
*/
|
|
11
|
+
var core_1 = require("@angular-devkit/core");
|
|
12
|
+
/**
|
|
13
|
+
* Find the component referred by a set of options passed to the schematics.
|
|
14
|
+
*/
|
|
15
|
+
function findComponentFromOptions(host, options) {
|
|
16
|
+
if (options.hasOwnProperty('skipImport') && options.skipImport) {
|
|
17
|
+
return undefined;
|
|
18
|
+
}
|
|
19
|
+
if (!options.component) {
|
|
20
|
+
var pathToCheck = (options.path || '') +
|
|
21
|
+
(options.flat ? '' : '/' + core_1.strings.dasherize(options.name));
|
|
22
|
+
return core_1.normalize(findComponent(host, pathToCheck));
|
|
23
|
+
}
|
|
24
|
+
else {
|
|
25
|
+
var componentPath = core_1.normalize('/' + options.path + '/' + options.component);
|
|
26
|
+
var componentBaseName = core_1.normalize(componentPath).split('/').pop();
|
|
27
|
+
if (host.exists(componentPath)) {
|
|
28
|
+
return core_1.normalize(componentPath);
|
|
29
|
+
}
|
|
30
|
+
else if (host.exists(componentPath + '.ts')) {
|
|
31
|
+
return core_1.normalize(componentPath + '.ts');
|
|
32
|
+
}
|
|
33
|
+
else if (host.exists(componentPath + '.component.ts')) {
|
|
34
|
+
return core_1.normalize(componentPath + '.component.ts');
|
|
35
|
+
}
|
|
36
|
+
else if (host.exists(componentPath + '/' + componentBaseName + '.component.ts')) {
|
|
37
|
+
return core_1.normalize(componentPath + '/' + componentBaseName + '.component.ts');
|
|
38
|
+
}
|
|
39
|
+
else {
|
|
40
|
+
throw new Error("Specified component path " + componentPath + " does not exist");
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
exports.findComponentFromOptions = findComponentFromOptions;
|
|
45
|
+
/**
|
|
46
|
+
* Function to find the "closest" component to a generated file's path.
|
|
47
|
+
*/
|
|
48
|
+
function findComponent(host, generateDir) {
|
|
49
|
+
var dir = host.getDir('/' + generateDir);
|
|
50
|
+
var componentRe = /\.component\.ts$/;
|
|
51
|
+
while (dir) {
|
|
52
|
+
var matches = dir.subfiles.filter(function (p) { return componentRe.test(p); });
|
|
53
|
+
if (matches.length == 1) {
|
|
54
|
+
return core_1.join(dir.path, matches[0]);
|
|
55
|
+
}
|
|
56
|
+
else if (matches.length > 1) {
|
|
57
|
+
throw new Error('More than one component matches. Use skip-import option to skip importing ' +
|
|
58
|
+
'the component store into the closest component.');
|
|
59
|
+
}
|
|
60
|
+
dir = dir.parent;
|
|
61
|
+
}
|
|
62
|
+
throw new Error('Could not find an Component. Use the skip-import ' +
|
|
63
|
+
'option to skip importing in Component.');
|
|
64
|
+
}
|
|
65
|
+
exports.findComponent = findComponent;
|
|
66
|
+
/**
|
|
67
|
+
* Build a relative path from one file path to another file path.
|
|
68
|
+
*/
|
|
69
|
+
function buildRelativePath(from, to) {
|
|
70
|
+
var _a = parsePath(from), fromPath = _a.path, fromFileName = _a.filename, fromDirectory = _a.directory;
|
|
71
|
+
var _b = parsePath(to), toPath = _b.path, toFileName = _b.filename, toDirectory = _b.directory;
|
|
72
|
+
var relativePath = core_1.relative(fromDirectory, toDirectory);
|
|
73
|
+
var fixedRelativePath = relativePath.startsWith('.')
|
|
74
|
+
? relativePath
|
|
75
|
+
: "./" + relativePath;
|
|
76
|
+
return !toFileName || toFileName === 'index.ts'
|
|
77
|
+
? fixedRelativePath
|
|
78
|
+
: "" + (fixedRelativePath.endsWith('/')
|
|
79
|
+
? fixedRelativePath
|
|
80
|
+
: fixedRelativePath + '/') + convertToTypeScriptFileName(toFileName);
|
|
81
|
+
}
|
|
82
|
+
exports.buildRelativePath = buildRelativePath;
|
|
83
|
+
function parsePath(path) {
|
|
84
|
+
var pathNormalized = core_1.normalize(path);
|
|
85
|
+
var filename = core_1.extname(pathNormalized) ? core_1.basename(pathNormalized) : '';
|
|
86
|
+
var directory = filename ? core_1.dirname(pathNormalized) : pathNormalized;
|
|
87
|
+
return {
|
|
88
|
+
path: pathNormalized,
|
|
89
|
+
filename: filename,
|
|
90
|
+
directory: directory
|
|
91
|
+
};
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* Strips the typescript extension and clears index filenames
|
|
95
|
+
* foo.ts -> foo
|
|
96
|
+
* index.ts -> empty
|
|
97
|
+
*/
|
|
98
|
+
function convertToTypeScriptFileName(filename) {
|
|
99
|
+
return filename ? filename.replace(/(\.ts)|(index\.ts)$/, '') : '';
|
|
100
|
+
}
|
|
101
|
+
//# sourceMappingURL=find-component.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"find-component.js","sourceRoot":"","sources":["../../../../../modules/entity/schematics-core/utility/find-component.ts"],"names":[],"mappings":";;;AAAA;;;;;;GAMG;AACH,6CAS8B;AAW9B;;GAEG;AACH,SAAgB,wBAAwB,CACtC,IAAU,EACV,OAAyB;IAEzB,IAAI,OAAO,CAAC,cAAc,CAAC,YAAY,CAAC,IAAI,OAAO,CAAC,UAAU,EAAE;QAC9D,OAAO,SAAS,CAAC;KAClB;IAED,IAAI,CAAC,OAAO,CAAC,SAAS,EAAE;QACtB,IAAM,WAAW,GACf,CAAC,OAAO,CAAC,IAAI,IAAI,EAAE,CAAC;YACpB,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,GAAG,cAAO,CAAC,SAAS,CAAC,OAAO,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AAC,IAAY;IAC7B,IAAM,cAAc,GAAG,gBAAS,CAAC,IAAI,CAAS,CAAC;IAC/C,IAAM,QAAQ,GAAG,cAAO,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC,eAAQ,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;IACzE,IAAM,SAAS,GAAG,QAAQ,CAAC,CAAC,CAAC,cAAO,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC,cAAc,CAAC;IACtE,OAAO;QACL,IAAI,EAAE,cAAc;QACpB,QAAQ,UAAA;QACR,SAAS,WAAA;KACV,CAAC;AACJ,CAAC;AACD;;;;GAIG;AACH,SAAS,2BAA2B,CAAC,QAA4B;IAC/D,OAAO,QAAQ,CAAC,CAAC,CAAC,QAAQ,CAAC,OAAO,CAAC,qBAAqB,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;AACrE,CAAC","sourcesContent":["/**\n * @license\n * Copyright Google Inc. All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\nimport {\n Path,\n join,\n normalize,\n relative,\n strings,\n basename,\n extname,\n dirname,\n} from '@angular-devkit/core';\nimport { DirEntry, Tree } from '@angular-devkit/schematics';\n\nexport interface ComponentOptions {\n component?: string;\n name: string;\n flat?: boolean;\n path?: string;\n skipImport?: boolean;\n}\n\n/**\n * Find the component referred by a set of options passed to the schematics.\n */\nexport function findComponentFromOptions(\n host: Tree,\n options: ComponentOptions\n): Path | undefined {\n if (options.hasOwnProperty('skipImport') && options.skipImport) {\n return undefined;\n }\n\n if (!options.component) {\n const pathToCheck =\n (options.path || '') +\n (options.flat ? '' : '/' + strings.dasherize(options.name));\n\n return normalize(findComponent(host, pathToCheck));\n } else {\n const componentPath = normalize(\n '/' + options.path + '/' + options.component\n );\n const componentBaseName = normalize(componentPath).split('/').pop();\n\n if (host.exists(componentPath)) {\n return normalize(componentPath);\n } else if (host.exists(componentPath + '.ts')) {\n return normalize(componentPath + '.ts');\n } else if (host.exists(componentPath + '.component.ts')) {\n return normalize(componentPath + '.component.ts');\n } else if (\n host.exists(componentPath + '/' + componentBaseName + '.component.ts')\n ) {\n return normalize(\n componentPath + '/' + componentBaseName + '.component.ts'\n );\n } else {\n throw new Error(\n `Specified component path ${componentPath} does not exist`\n );\n }\n }\n}\n\n/**\n * Function to find the \"closest\" component to a generated file's path.\n */\nexport function findComponent(host: Tree, generateDir: string): Path {\n let dir: DirEntry | null = host.getDir('/' + generateDir);\n\n const componentRe = /\\.component\\.ts$/;\n\n while (dir) {\n const matches = dir.subfiles.filter((p) => componentRe.test(p));\n\n if (matches.length == 1) {\n return join(dir.path, matches[0]);\n } else if (matches.length > 1) {\n throw new Error(\n 'More than one component matches. Use skip-import option to skip importing ' +\n 'the component store into the closest component.'\n );\n }\n\n dir = dir.parent;\n }\n\n throw new Error(\n 'Could not find an Component. Use the skip-import ' +\n 'option to skip importing in Component.'\n );\n}\n\n/**\n * Build a relative path from one file path to another file path.\n */\nexport function buildRelativePath(from: string, to: string): string {\n const {\n path: fromPath,\n filename: fromFileName,\n directory: fromDirectory,\n } = parsePath(from);\n const {\n path: toPath,\n filename: toFileName,\n directory: toDirectory,\n } = parsePath(to);\n const relativePath = relative(fromDirectory, toDirectory);\n const fixedRelativePath = relativePath.startsWith('.')\n ? relativePath\n : `./${relativePath}`;\n\n return !toFileName || toFileName === 'index.ts'\n ? fixedRelativePath\n : `${\n fixedRelativePath.endsWith('/')\n ? fixedRelativePath\n : fixedRelativePath + '/'\n }${convertToTypeScriptFileName(toFileName)}`;\n}\n\nfunction parsePath(path: string) {\n const pathNormalized = normalize(path) as Path;\n const filename = extname(pathNormalized) ? basename(pathNormalized) : '';\n const directory = filename ? dirname(pathNormalized) : pathNormalized;\n return {\n path: pathNormalized,\n filename,\n directory,\n };\n}\n/**\n * Strips the typescript extension and clears index filenames\n * foo.ts -> foo\n * index.ts -> empty\n */\nfunction convertToTypeScriptFileName(filename: string | undefined) {\n return filename ? filename.replace(/(\\.ts)|(index\\.ts)$/, '') : '';\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"libs-version.js","sourceRoot":"","sources":["../../../../../modules/entity/schematics-core/utility/libs-version.ts"],"names":[],"mappings":";;;AAAa,QAAA,eAAe,GAAG,
|
|
1
|
+
{"version":3,"file":"libs-version.js","sourceRoot":"","sources":["../../../../../modules/entity/schematics-core/utility/libs-version.ts"],"names":[],"mappings":";;;AAAa,QAAA,eAAe,GAAG,SAAS,CAAC","sourcesContent":["export const platformVersion = '^11.1.1';\n"]}
|
|
@@ -5,9 +5,11 @@ var config_1 = require("./config");
|
|
|
5
5
|
function getProject(host, options) {
|
|
6
6
|
var workspace = config_1.getWorkspace(host);
|
|
7
7
|
if (!options.project) {
|
|
8
|
+
var defaultProject = workspace
|
|
9
|
+
.defaultProject;
|
|
8
10
|
options.project =
|
|
9
|
-
|
|
10
|
-
?
|
|
11
|
+
defaultProject !== undefined
|
|
12
|
+
? defaultProject
|
|
11
13
|
: Object.keys(workspace.projects)[0];
|
|
12
14
|
}
|
|
13
15
|
return workspace.projects[options.project];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"project.js","sourceRoot":"","sources":["../../../../../modules/entity/schematics-core/utility/project.ts"],"names":[],"mappings":";;;AAAA,mCAAwC;AAQxC,SAAgB,UAAU,CACxB,IAAU,EACV,OAAoE;IAEpE,IAAM,SAAS,GAAG,qBAAY,CAAC,IAAI,CAAC,CAAC;IAErC,IAAI,CAAC,OAAO,CAAC,OAAO,EAAE;QACpB,OAAO,CAAC,OAAO;YACb,
|
|
1
|
+
{"version":3,"file":"project.js","sourceRoot":"","sources":["../../../../../modules/entity/schematics-core/utility/project.ts"],"names":[],"mappings":";;;AAAA,mCAAwC;AAQxC,SAAgB,UAAU,CACxB,IAAU,EACV,OAAoE;IAEpE,IAAM,SAAS,GAAG,qBAAY,CAAC,IAAI,CAAC,CAAC;IAErC,IAAI,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orkspace } from './config';\nimport { Tree } from '@angular-devkit/schematics';\n\nexport interface WorkspaceProject {\n root: string;\n projectType: string;\n}\n\nexport function getProject(\n host: Tree,\n options: { project?: string | undefined; path?: string | undefined }\n): WorkspaceProject {\n const workspace = getWorkspace(host);\n\n if (!options.project) {\n const defaultProject = (workspace as { defaultProject?: string })\n .defaultProject;\n options.project =\n defaultProject !== undefined\n ? defaultProject\n : Object.keys(workspace.projects)[0];\n }\n\n return workspace.projects[options.project];\n}\n\nexport function getProjectPath(\n host: Tree,\n options: { project?: string | undefined; path?: string | undefined }\n) {\n const project = getProject(host, options);\n\n if (project.root.substr(-1) === '/') {\n project.root = project.root.substr(0, project.root.length - 1);\n }\n\n if (options.path === undefined) {\n const projectDirName =\n project.projectType === 'application' ? 'app' : 'lib';\n\n return `${project.root ? `/${project.root}` : ''}/src/${projectDirName}`;\n }\n\n return options.path;\n}\n\nexport function isLib(\n host: Tree,\n options: { project?: string | undefined; path?: string | undefined }\n) {\n const project = getProject(host, options);\n\n return project.projectType === 'library';\n}\n"]}
|
package/CHANGELOG.md
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"moduleName":null,"summaries":[{"symbol":{"__symbol":0,"members":[]},"metadata":{"__symbol":1,"members":[]}},{"symbol":{"__symbol":2,"members":[]},"metadata":{"__symbol":3,"members":[]}},{"symbol":{"__symbol":4,"members":[]},"metadata":{"__symbol":5,"members":[]}},{"symbol":{"__symbol":6,"members":[]},"metadata":{"__symbol":7,"members":[]}},{"symbol":{"__symbol":8,"members":[]},"metadata":{"__symbol":9,"members":[]}},{"symbol":{"__symbol":10,"members":[]},"metadata":{"__symbol":11,"members":[]}},{"symbol":{"__symbol":12,"members":[]},"metadata":{"__symbol":13,"members":[]}},{"symbol":{"__symbol":14,"members":[]},"metadata":{"__symbol":15,"members":[]}},{"symbol":{"__symbol":16,"members":[]},"metadata":{"__symbol":17,"members":[]}},{"symbol":{"__symbol":18,"members":[]},"metadata":{"__symbol":19,"members":[]}}],"symbols":[{"__symbol":0,"name":"createEntityAdapter","filePath":"./index"},{"__symbol":1,"name":"createEntityAdapter","filePath":"./public_api"},{"__symbol":2,"name":"Dictionary","filePath":"./index"},{"__symbol":3,"name":"Dictionary","filePath":"./public_api"},{"__symbol":4,"name":"EntityState","filePath":"./index"},{"__symbol":5,"name":"EntityState","filePath":"./public_api"},{"__symbol":6,"name":"EntityAdapter","filePath":"./index"},{"__symbol":7,"name":"EntityAdapter","filePath":"./public_api"},{"__symbol":8,"name":"Update","filePath":"./index"},{"__symbol":9,"name":"Update","filePath":"./public_api"},{"__symbol":10,"name":"EntityMap","filePath":"./index"},{"__symbol":11,"name":"EntityMap","filePath":"./public_api"},{"__symbol":12,"name":"EntityMapOne","filePath":"./index"},{"__symbol":13,"name":"EntityMapOne","filePath":"./public_api"},{"__symbol":14,"name":"Predicate","filePath":"./index"},{"__symbol":15,"name":"Predicate","filePath":"./public_api"},{"__symbol":16,"name":"IdSelector","filePath":"./index"},{"__symbol":17,"name":"IdSelector","filePath":"./public_api"},{"__symbol":18,"name":"Comparer","filePath":"./index"},{"__symbol":19,"name":"Comparer","filePath":"./public_api"}]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"moduleName":null,"summaries":[{"symbol":{"__symbol":0,"members":[]},"metadata":{"__symbol":1,"members":[]}},{"symbol":{"__symbol":2,"members":[]},"metadata":{"__symbol":3,"members":[]}},{"symbol":{"__symbol":4,"members":[]},"metadata":{"__symbol":5,"members":[]}},{"symbol":{"__symbol":6,"members":[]},"metadata":{"__symbol":7,"members":[]}},{"symbol":{"__symbol":8,"members":[]},"metadata":{"__symbol":9,"members":[]}},{"symbol":{"__symbol":10,"members":[]},"metadata":{"__symbol":11,"members":[]}},{"symbol":{"__symbol":12,"members":[]},"metadata":{"__symbol":13,"members":[]}},{"symbol":{"__symbol":14,"members":[]},"metadata":{"__symbol":15,"members":[]}},{"symbol":{"__symbol":16,"members":[]},"metadata":{"__symbol":17,"members":[]}},{"symbol":{"__symbol":18,"members":[]},"metadata":{"__symbol":19,"members":[]}}],"symbols":[{"__symbol":0,"name":"createEntityAdapter","filePath":"./ngrx-entity"},{"__symbol":1,"name":"createEntityAdapter","filePath":"./index"},{"__symbol":2,"name":"Dictionary","filePath":"./ngrx-entity"},{"__symbol":3,"name":"Dictionary","filePath":"./index"},{"__symbol":4,"name":"EntityState","filePath":"./ngrx-entity"},{"__symbol":5,"name":"EntityState","filePath":"./index"},{"__symbol":6,"name":"EntityAdapter","filePath":"./ngrx-entity"},{"__symbol":7,"name":"EntityAdapter","filePath":"./index"},{"__symbol":8,"name":"Update","filePath":"./ngrx-entity"},{"__symbol":9,"name":"Update","filePath":"./index"},{"__symbol":10,"name":"EntityMap","filePath":"./ngrx-entity"},{"__symbol":11,"name":"EntityMap","filePath":"./index"},{"__symbol":12,"name":"EntityMapOne","filePath":"./ngrx-entity"},{"__symbol":13,"name":"EntityMapOne","filePath":"./index"},{"__symbol":14,"name":"Predicate","filePath":"./ngrx-entity"},{"__symbol":15,"name":"Predicate","filePath":"./index"},{"__symbol":16,"name":"IdSelector","filePath":"./ngrx-entity"},{"__symbol":17,"name":"IdSelector","filePath":"./index"},{"__symbol":18,"name":"Comparer","filePath":"./ngrx-entity"},{"__symbol":19,"name":"Comparer","filePath":"./index"}]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"moduleName":null,"summaries":[{"symbol":{"__symbol":0,"members":[]},"metadata":{"__symbol":1,"members":[]}},{"symbol":{"__symbol":2,"members":[]},"metadata":{"__symbol":3,"members":[]}},{"symbol":{"__symbol":4,"members":[]},"metadata":{"__symbol":5,"members":[]}},{"symbol":{"__symbol":6,"members":[]},"metadata":{"__symbol":7,"members":[]}},{"symbol":{"__symbol":8,"members":[]},"metadata":{"__symbol":9,"members":[]}},{"symbol":{"__symbol":10,"members":[]},"metadata":{"__symbol":11,"members":[]}},{"symbol":{"__symbol":12,"members":[]},"metadata":{"__symbol":13,"members":[]}},{"symbol":{"__symbol":14,"members":[]},"metadata":{"__symbol":15,"members":[]}},{"symbol":{"__symbol":16,"members":[]},"metadata":{"__symbol":17,"members":[]}},{"symbol":{"__symbol":18,"members":[]},"metadata":{"__symbol":19,"members":[]}}],"symbols":[{"__symbol":0,"name":"createEntityAdapter","filePath":"./public_api"},{"__symbol":1,"name":"createEntityAdapter","filePath":"./src/index"},{"__symbol":2,"name":"Dictionary","filePath":"./public_api"},{"__symbol":3,"name":"Dictionary","filePath":"./src/index"},{"__symbol":4,"name":"EntityState","filePath":"./public_api"},{"__symbol":5,"name":"EntityState","filePath":"./src/index"},{"__symbol":6,"name":"EntityAdapter","filePath":"./public_api"},{"__symbol":7,"name":"EntityAdapter","filePath":"./src/index"},{"__symbol":8,"name":"Update","filePath":"./public_api"},{"__symbol":9,"name":"Update","filePath":"./src/index"},{"__symbol":10,"name":"EntityMap","filePath":"./public_api"},{"__symbol":11,"name":"EntityMap","filePath":"./src/index"},{"__symbol":12,"name":"EntityMapOne","filePath":"./public_api"},{"__symbol":13,"name":"EntityMapOne","filePath":"./src/index"},{"__symbol":14,"name":"Predicate","filePath":"./public_api"},{"__symbol":15,"name":"Predicate","filePath":"./src/index"},{"__symbol":16,"name":"IdSelector","filePath":"./public_api"},{"__symbol":17,"name":"IdSelector","filePath":"./src/index"},{"__symbol":18,"name":"Comparer","filePath":"./public_api"},{"__symbol":19,"name":"Comparer","filePath":"./src/index"}]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"moduleName":null,"summaries":[{"symbol":{"__symbol":0,"members":[]},"metadata":{"__symbolic":"function"}}],"symbols":[{"__symbol":0,"name":"createEntityAdapter","filePath":"./create_adapter"}]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"moduleName":null,"summaries":[{"symbol":{"__symbol":0,"members":[]},"metadata":{"__symbolic":"function","parameters":[],"value":{"ids":[],"entities":{}}}},{"symbol":{"__symbol":1,"members":[]},"metadata":{"__symbolic":"function"}}],"symbols":[{"__symbol":0,"name":"getInitialEntityState","filePath":"./entity_state"},{"__symbol":1,"name":"createInitialStateFactory","filePath":"./entity_state"}]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"moduleName":null,"summaries":[{"symbol":{"__symbol":0,"members":[]},"metadata":{"__symbol":1,"members":[]}},{"symbol":{"__symbol":2,"members":[]},"metadata":{"__symbol":3,"members":[]}},{"symbol":{"__symbol":4,"members":[]},"metadata":{"__symbol":5,"members":[]}},{"symbol":{"__symbol":6,"members":[]},"metadata":{"__symbol":7,"members":[]}},{"symbol":{"__symbol":8,"members":[]},"metadata":{"__symbol":9,"members":[]}},{"symbol":{"__symbol":10,"members":[]},"metadata":{"__symbol":11,"members":[]}},{"symbol":{"__symbol":12,"members":[]},"metadata":{"__symbol":13,"members":[]}},{"symbol":{"__symbol":14,"members":[]},"metadata":{"__symbol":15,"members":[]}},{"symbol":{"__symbol":16,"members":[]},"metadata":{"__symbol":17,"members":[]}},{"symbol":{"__symbol":18,"members":[]},"metadata":{"__symbol":19,"members":[]}}],"symbols":[{"__symbol":0,"name":"createEntityAdapter","filePath":"./index"},{"__symbol":1,"name":"createEntityAdapter","filePath":"./create_adapter"},{"__symbol":2,"name":"Dictionary","filePath":"./index"},{"__symbol":3,"name":"Dictionary","filePath":"./models"},{"__symbol":4,"name":"EntityState","filePath":"./index"},{"__symbol":5,"name":"EntityState","filePath":"./models"},{"__symbol":6,"name":"EntityAdapter","filePath":"./index"},{"__symbol":7,"name":"EntityAdapter","filePath":"./models"},{"__symbol":8,"name":"Update","filePath":"./index"},{"__symbol":9,"name":"Update","filePath":"./models"},{"__symbol":10,"name":"EntityMap","filePath":"./index"},{"__symbol":11,"name":"EntityMap","filePath":"./models"},{"__symbol":12,"name":"EntityMapOne","filePath":"./index"},{"__symbol":13,"name":"EntityMapOne","filePath":"./models"},{"__symbol":14,"name":"Predicate","filePath":"./index"},{"__symbol":15,"name":"Predicate","filePath":"./models"},{"__symbol":16,"name":"IdSelector","filePath":"./index"},{"__symbol":17,"name":"IdSelector","filePath":"./models"},{"__symbol":18,"name":"Comparer","filePath":"./index"},{"__symbol":19,"name":"Comparer","filePath":"./models"}]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"moduleName":null,"summaries":[{"symbol":{"__symbol":0,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":1,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":2,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":3,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":4,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":5,"members":[]},"metadata":{"__symbolic":"class","arity":1}},{"symbol":{"__symbol":6,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":7,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":8,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":9,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":10,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":11,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":12,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":13,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":14,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":15,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":16,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":17,"members":[]},"metadata":{"__symbolic":"interface"}},{"symbol":{"__symbol":18,"members":[]},"metadata":{"__symbolic":"interface"}}],"symbols":[{"__symbol":0,"name":"Comparer","filePath":"./models"},{"__symbol":1,"name":"IdSelectorStr","filePath":"./models"},{"__symbol":2,"name":"IdSelectorNum","filePath":"./models"},{"__symbol":3,"name":"IdSelector","filePath":"./models"},{"__symbol":4,"name":"DictionaryNum","filePath":"./models"},{"__symbol":5,"name":"Dictionary","filePath":"./models"},{"__symbol":6,"name":"UpdateStr","filePath":"./models"},{"__symbol":7,"name":"UpdateNum","filePath":"./models"},{"__symbol":8,"name":"Update","filePath":"./models"},{"__symbol":9,"name":"Predicate","filePath":"./models"},{"__symbol":10,"name":"EntityMap","filePath":"./models"},{"__symbol":11,"name":"EntityMapOneNum","filePath":"./models"},{"__symbol":12,"name":"EntityMapOneStr","filePath":"./models"},{"__symbol":13,"name":"EntityMapOne","filePath":"./models"},{"__symbol":14,"name":"EntityState","filePath":"./models"},{"__symbol":15,"name":"EntityDefinition","filePath":"./models"},{"__symbol":16,"name":"EntityStateAdapter","filePath":"./models"},{"__symbol":17,"name":"EntitySelectors","filePath":"./models"},{"__symbol":18,"name":"EntityAdapter","filePath":"./models"}]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"moduleName":null,"summaries":[{"symbol":{"__symbol":0,"members":[]},"metadata":{"__symbolic":"function"}}],"symbols":[{"__symbol":0,"name":"createSortedStateAdapter","filePath":"./sorted_state_adapter"}]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"moduleName":null,"summaries":[{"symbol":{"__symbol":0,"members":[]},"metadata":{"EntitiesOnly":0,"Both":1,"None":2}},{"symbol":{"__symbol":1,"members":[]},"metadata":{"__symbolic":"function","parameters":["mutator"],"value":{"__symbolic":"error","message":"Lambda not supported","fileName":"modules/entity/src/state_adapter.ts"}}}],"symbols":[{"__symbol":0,"name":"DidMutate","filePath":"./state_adapter"},{"__symbol":1,"name":"createStateOperator","filePath":"./state_adapter"}]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"moduleName":null,"summaries":[{"symbol":{"__symbol":0,"members":[]},"metadata":{"__symbolic":"function"}}],"symbols":[{"__symbol":0,"name":"createSelectorsFactory","filePath":"./state_selectors"}]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"moduleName":null,"summaries":[{"symbol":{"__symbol":0,"members":[]},"metadata":{"__symbolic":"function"}}],"symbols":[{"__symbol":0,"name":"createUnsortedStateAdapter","filePath":"./unsorted_state_adapter"}]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"moduleName":null,"summaries":[{"symbol":{"__symbol":0,"members":[]},"metadata":{"__symbolic":"function"}}],"symbols":[{"__symbol":0,"name":"selectIdValue","filePath":"./utils"}]}
|