mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
Specs: Make it possible to import a module from a module or application by calling module.import(url)
Review URL: https://codereview.chromium.org/690793002
This commit is contained in:
parent
b50d01ca6b
commit
945193eb86
@ -172,15 +172,18 @@ module 'sky:core' {
|
||||
|
||||
|
||||
// MODULES
|
||||
abstract interface AbstractModule : EventTarget {
|
||||
Promise<any> import(String url); // O(Yikes) // returns the module's exports
|
||||
}
|
||||
|
||||
interface Module : EventTarget {
|
||||
interface Module : AbstractModule {
|
||||
constructor (Application application, Document document); // O(1)
|
||||
attribute any exports; // O(1) // defaults to the module's document
|
||||
readonly attribute Document document; // O(1) // the module's document
|
||||
readonly attribute Application application; // O(1)
|
||||
}
|
||||
|
||||
interface Application : EventTarget {
|
||||
interface Application : AbstractModule {
|
||||
constructor (Document document); // O(1)
|
||||
attribute String title; // O(1)
|
||||
readonly attribute Document document; // O(1) // the application's document
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user