Skip to content

Commit dd2547f

Browse files
chore(git): add missed files
1 parent a700627 commit dd2547f

File tree

3 files changed

+972
-0
lines changed

3 files changed

+972
-0
lines changed

dist/aurelia-framework.d.ts

Lines changed: 222 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,222 @@
1+
declare module 'aurelia-framework' {
2+
import core from 'core-js';
3+
import * as TheLogManager from 'aurelia-logging';
4+
import { Metadata } from 'aurelia-metadata';
5+
import { Container } from 'aurelia-dependency-injection';
6+
import { Loader } from 'aurelia-loader';
7+
import { join, relativeToFile } from 'aurelia-path';
8+
import { BindingLanguage, ViewEngine, ViewSlot, ResourceRegistry, CompositionEngine, Animator, DOMBoundary } from 'aurelia-templating';
9+
10+
/**
11+
* Manages loading and configuring plugins.
12+
*
13+
* @class Plugins
14+
* @constructor
15+
* @param {Aurelia} aurelia An instance of Aurelia.
16+
*/
17+
export class Plugins {
18+
constructor(aurelia: Aurelia);
19+
20+
/**
21+
* Configures an internal feature plugin before Aurelia starts.
22+
*
23+
* @method feature
24+
* @param {string} plugin The folder for the internal plugin to configure (expects an index.js in that folder).
25+
* @param {config} config The configuration for the specified plugin.
26+
* @return {Plugins} Returns the current Plugins instance.
27+
*/
28+
feature(plugin: string, config: any): Plugins;
29+
30+
/**
31+
* Configures an external, 3rd party plugin before Aurelia starts.
32+
*
33+
* @method plugin
34+
* @param {string} plugin The ID of the 3rd party plugin to configure.
35+
* @param {config} config The configuration for the specified plugin.
36+
* @return {Plugins} Returns the current Plugins instance.
37+
*/
38+
plugin(plugin: string, config: any): Plugins;
39+
40+
/**
41+
* Plugs in the default binding language from aurelia-templating-binding.
42+
*
43+
* @method defaultBindingLanguage
44+
* @return {Plugins} Returns the current Plugins instance.
45+
*/
46+
defaultBindingLanguage(): Plugins;
47+
48+
/**
49+
* Plugs in the router from aurelia-templating-router.
50+
*
51+
* @method router
52+
* @return {Plugins} Returns the current Plugins instance.
53+
*/
54+
router(): Plugins;
55+
56+
/**
57+
* Plugs in the default history implementation from aurelia-history-browser.
58+
*
59+
* @method history
60+
* @return {Plugins} Returns the current Plugins instance.
61+
*/
62+
history(): Plugins;
63+
64+
/**
65+
* Plugs in the default templating resources (if, repeat, show, compose, etc.) from aurelia-templating-resources.
66+
*
67+
* @method defaultResources
68+
* @return {Plugins} Returns the current Plugins instance.
69+
*/
70+
defaultResources(): Plugins;
71+
72+
/**
73+
* Plugs in the event aggregator from aurelia-event-aggregator.
74+
*
75+
* @method eventAggregator
76+
* @return {Plugins} Returns the current Plugins instance.
77+
*/
78+
eventAggregator(): Plugins;
79+
80+
/**
81+
* Sets up the Aurelia configuration. This is equivalent to calling `.defaultBindingLanguage().defaultResources().history().router().eventAggregator();`
82+
*
83+
* @method standardConfiguration
84+
* @return {Plugins} Returns the current Plugins instance.
85+
*/
86+
standardConfiguration(): Plugins;
87+
88+
/**
89+
* Plugs in the ConsoleAppender and sets the log level to debug.
90+
*
91+
* @method developmentLogging
92+
* @return {Plugins} Returns the current Plugins instance.
93+
*/
94+
developmentLogging(): Plugins;
95+
}
96+
97+
/**
98+
* The framework core that provides the main Aurelia object.
99+
*
100+
* @class Aurelia
101+
* @constructor
102+
* @param {Loader} loader The loader for this Aurelia instance to use. If a loader is not specified, Aurelia will use a defaultLoader.
103+
* @param {Container} container The dependency injection container for this Aurelia instance to use. If a container is not specified, Aurelia will create an empty container.
104+
* @param {ResourceRegistry} resources The resource registry for this Aurelia instance to use. If a resource registry is not specified, Aurelia will create an empty registry.
105+
*/
106+
export class Aurelia {
107+
loader: Loader;
108+
container: Container;
109+
resources: ResourceRegistry;
110+
use: Plugins;
111+
constructor(loader?: Loader, container?: Container, resources?: ResourceRegistry);
112+
113+
/**
114+
* Adds an existing object to the framework's dependency injection container.
115+
*
116+
* @method withInstance
117+
* @param {Class} type The object type of the dependency that the framework will inject.
118+
* @param {Object} instance The existing instance of the dependency that the framework will inject.
119+
* @return {Aurelia} Returns the current Aurelia instance.
120+
*/
121+
withInstance(type: any, instance: any): Aurelia;
122+
123+
/**
124+
* Adds a singleton to the framework's dependency injection container.
125+
*
126+
* @method withSingleton
127+
* @param {Class} type The object type of the dependency that the framework will inject.
128+
* @param {Object} implementation The constructor function of the dependency that the framework will inject.
129+
* @return {Aurelia} Returns the current Aurelia instance.
130+
*/
131+
withSingleton(type: any, implementation?: Function): Aurelia;
132+
133+
/**
134+
* Adds a transient to the framework's dependency injection container.
135+
*
136+
* @method withTransient
137+
* @param {Class} type The object type of the dependency that the framework will inject.
138+
* @param {Object} implementation The constructor function of the dependency that the framework will inject.
139+
* @return {Aurelia} Returns the current Aurelia instance.
140+
*/
141+
withTransient(type: any, implementation?: Function): Aurelia;
142+
143+
/**
144+
* Adds globally available view resources to be imported into the Aurelia framework.
145+
*
146+
* @method globalizeResources
147+
* @param {Object|Array} resources The relative module id to the resource. (Relative to the plugin's installer.)
148+
* @return {Aurelia} Returns the current Aurelia instance.
149+
*/
150+
globalizeResources(resources: string | string[]): Aurelia;
151+
152+
/**
153+
* Renames a global resource that was imported.
154+
*
155+
* @method renameGlobalResource
156+
* @param {String} resourcePath The path to the resource.
157+
* @param {String} newName The new name.
158+
* @return {Aurelia} Returns the current Aurelia instance.
159+
*/
160+
renameGlobalResource(resourcePath: string, newName: string): Aurelia;
161+
162+
/**
163+
* Adds an async function that runs before the plugins are run.
164+
*
165+
* @method addPreStartTask
166+
* @param {Function} task The function to run before start.
167+
* @return {Aurelia} Returns the current Aurelia instance.
168+
*/
169+
addPreStartTask(task: Function): Aurelia;
170+
171+
/**
172+
* Adds an async function that runs after the plugins are run.
173+
*
174+
* @method addPostStartTask
175+
* @param {Function} task The function to run after start.
176+
* @return {Aurelia} Returns the current Aurelia instance.
177+
*/
178+
addPostStartTask(task: Function): Aurelia;
179+
180+
/**
181+
* Loads plugins, then resources, and then starts the Aurelia instance.
182+
*
183+
* @method start
184+
* @return {Promise<Aurelia>} Returns the started Aurelia instance.
185+
*/
186+
start(): Promise<Aurelia>;
187+
188+
/**
189+
* Enhances the host's existing elements with behaviors and bindings.
190+
*
191+
* @method enhance
192+
* @param {Object} bindingContext A binding context for the enhanced elements.
193+
* @param {string|Object} applicationHost The DOM object that Aurelia will enhance.
194+
* @return {Promise<Aurelia>} Returns the current Aurelia instance.
195+
*/
196+
enhance(bindingContext?: Object, applicationHost?: any): Promise<Aurelia>;
197+
198+
/**
199+
* Instantiates the root view-model and view and add them to the DOM.
200+
*
201+
* @method setRoot
202+
* @param {Object} root The root view-model to load upon bootstrap.
203+
* @param {string|Object} applicationHost The DOM object that Aurelia will attach to.
204+
* @return {Promise<Aurelia>} Returns the current Aurelia instance.
205+
*/
206+
setRoot(root?: string, applicationHost?: any): Promise<Aurelia>;
207+
}
208+
209+
/**
210+
* The aurelia framework brings together all the required core aurelia libraries into a ready-to-go application-building platform.
211+
*
212+
* @module framework
213+
*/
214+
export * from 'aurelia-dependency-injection';
215+
export * from 'aurelia-binding';
216+
export * from 'aurelia-metadata';
217+
export * from 'aurelia-templating';
218+
export * from 'aurelia-loader';
219+
export * from 'aurelia-task-queue';
220+
export * from 'aurelia-path';
221+
export var LogManager: any;
222+
}

0 commit comments

Comments
 (0)