Browse files

Add import.meta.url

This integrates with the stage 3 import.meta proposal located at This is based on
although it only includes the easier part, import.meta.url.
import.meta.scriptElement is still being discussed, at #1013, and as
such is excluded for now.
  • Loading branch information...
domenic committed Oct 18, 2017
1 parent e568aaa commit 177dd9dc60df084609ff5eef8bbfa2cdb26d4bf3
Showing with 28 additions and 0 deletions.
  1. +28 −0 source
28 source
@@ -3070,6 +3070,14 @@ a.setAttribute('href', ''); // change the content attribute
<li>The <dfn data-x-href="">FinishDynamicImport</dfn> abstract operation</li>
<p>Users agents that support JavaScript must also implement the <cite>import.meta</cite>
proposal. The following term is defined there, and used in this specification: <ref
<ul class="brief">
<li>The <dfn data-x="js-HostGetImportMetaProperties" data-x-href="">HostGetImportMetaProperties</dfn> abstract operation</li>
@@ -88215,6 +88223,23 @@ import "";</pre>
<li><p>Return undefined.</p></li>
<p>The <cite>import.meta</cite> proposal contains an implementation-defined <span
data-x="js-HostGetImportMetaProperties">HostGetImportMetaProperties</span> abstract operation.
User agents must use the following implementation: <ref spec=JSIMPORTMETA></p>
<li><p>Let <var>module script</var> be <var>moduleRecord</var>.[[HostDefined]].</p></li>
<li><p>Let <var>urlString</var> be <var>module script</var>'s <span
data-x="concept-script-base-url">base URL</span>, <span
<li><p>Return « Record { [[Key]]: "url", [[Value]]: <var>urlString</var> } ».</p></li>
<h5>Integration with the JavaScript agent formalism</h5>
<p>JavaScript defines the concept of an <span>agent</span>. Until such a time that this standard
@@ -119863,6 +119888,9 @@ INSERT INTERFACES HERE
<dt id="refsJSIMPORT">[JSIMPORT]</dt>
<dd><cite><a href="">import()</a></cite>. Ecma International.</dd>
<dd><cite><a href="">import.meta</a></cite>. Ecma International.</dd>
<dt id="refsJSINTL">[JSINTL]</dt>
<dd><cite><a href="">ECMAScript Internationalization API Specification</a></cite>. Ecma International.</dd>

0 comments on commit 177dd9d

Please sign in to comment.