From c5fd19e32c5149c5d6293064a5eb6978aab39c4e Mon Sep 17 00:00:00 2001 From: Yoav Weiss Date: Mon, 4 Nov 2024 10:25:44 +0100 Subject: [PATCH] Review comments --- source | 99 ++++++++++++++++++++++++++++------------------------------ 1 file changed, 48 insertions(+), 51 deletions(-) diff --git a/source b/source index 7151edfdeef..deb0173d0fd 100644 --- a/source +++ b/source @@ -62951,10 +62951,6 @@ document.body.append(script1, script2);
"module"
-

Let map be settings object's global object's import map.

-

If el does not have an integrity attribute, then set options's integrity metadata to the result of @@ -106168,22 +106164,6 @@ new PaymentRequest(…); // Allowed to use from the initial empty one. The import map is only accessed for the resolution of a root module script.

-

A specifier resolution record is a struct. It has the following items:

-
-
A serialized base - URL
-
A string-or-null that represents the base URL of the specifier, when one - exists.
- -
A specifier
-
A string representing the specifier.
- -
An asURL
-
A URL-or-null that represents the URL in case of a URL-like module - specifier.
-
-

A global object has a resolved module set, a set of specifier resolution records, initially empty.

@@ -106195,10 +106175,6 @@ new PaymentRequest(…); // Allowed to use global objects have their module set data structures modified from the initial empty one.

-

Implementations can replace - asURL with a boolean that indicates that - the specifier is either bare or URL-like that is special.

-

There is always a 1-to-1-to-1 mapping between realms,

Return newOptions.

-

To resolve a module - integrity metadata, given a URL url and an environment - settings object settingsObject:

+

To resolve a module integrity + metadata, given a URL url and an environment settings + object settingsObject:

  1. Let map be settingsObject's To fetch the descendants of and link a module script moduleScript, given an environment settings object fetchClient, a destination destination, an - algorithm onComplete, and an optional perform the fetch hook performFetch, run - these steps. onComplete must be an algorithm accepting null (on failure) or a - module script (on success).

    + data-x="concept-request-destination">destination destination, an algorithm + onComplete, and an optional perform the + fetch hook performFetch, run these steps. onComplete must be an + algorithm accepting null (on failure) or a module script (on success).

    1. Let record be moduleScript's module script (on success).

        -
      1. Assert: moduleRequest.[[Attributes]] does not contain any Record - entry such that entry.[[Key]] is not "type", because - we only asked for "type" attributes in +

      2. Assert: moduleRequest.[[Attributes]] does not contain any + Record entry such that entry.[[Key]] is not "type", because we only asked for "type" attributes in HostGetSupportedImportAttributes.

      3. Let moduleType be the result of running the module type from module @@ -108035,7 +108010,7 @@ document.querySelector("button").addEventListener("click", bound);

        To create a JavaScript module script, given a string source, an environment settings object settings, a URL baseURL, and a script fetch - options options: + options options:

        1. If scripting is disabled for @@ -108883,7 +108858,7 @@ dictionary PromiseRejectionEventInit : EventInit

          To resolve a module specifier given a script-or-null - referringScript, and a string specifier: + referringScript, and a string specifier:

          1. Let settingsObject and baseURL be null.

          2. @@ -109402,6 +109377,27 @@ dictionary PromiseRejectionEventInit : EventInit +

            A specifier resolution record is a struct. It has the following items:

            +
            +
            A serialized base + URL
            +
            A string-or-null that represents the base URL of the specifier, when one + exists.
            + +
            A specifier
            +
            A string representing the specifier.
            + +
            A specifier as a URL
            +
            A URL-or-null that represents the URL in case of a URL-like module + specifier.
            +
            + +

            Implementations can replace + specifier as a URL with a boolean that + indicates that the specifier is either bare or URL-like that is special.

            + +

            To add module to resolved module set given an environment settings object settingsObject, a string serializedBaseURL, a string normalizedSpecifier, and a URL-or-null @@ -109418,7 +109414,8 @@ dictionary PromiseRejectionEventInit : EventInitserializedBaseURL, specifier set to normalizedSpecifier, and asURL set to asURL.

            + data-x="specifier-resolution-record-as-url">specifier as a URL
            set to + asURL.

          3. Append record to global's resolved module set.

          4. @@ -109607,20 +109604,20 @@ dictionary PromiseRejectionEventInit : EventInit
          5. If specifierKey is record's specifier, or if the following - conditions are all true:

            + data-x="specifier-resolution-record-specifier">specifier, or if all of the + following conditions are true:

            -
              -
            1. specifierKey ends with U+002F (/).

            2. +
                +
              • specifierKey ends with U+002F (/);

              • specifierKey is a code unit prefix of record's specifier.

              • + data-x="specifier-resolution-record-specifier">specifier;

                -
              • Either record's asURL is null or is - special

              • -
            +
          6. either record's specifier as a URL is null or + is special,

          7. +

            then:

            @@ -109640,7 +109637,7 @@ dictionary PromiseRejectionEventInit : EventInitImplementers are encouraged to implement a more efficient matching algorithm when working with the resolved module set. As guidance, the number of - resolved/mapped modules in a large application can be in the order of thousands.

            + resolved/mapped modules in a large application can be on the order of thousands.

          8. If scopePrefix exists in @@ -109715,9 +109712,9 @@ dictionary PromiseRejectionEventInit : EventInitimports.

          -

          The above algorithm merges a new import map into the given environment - settings object's global object's import map. Let's examine a - few examples:

          +

          The above algorithm merges a new import map into the given environment settings + object's global object's import map. Let's examine a few + examples:

          There are two cases when rules of the new import map don't get merged into the existing