-
-
Notifications
You must be signed in to change notification settings - Fork 633
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: render runtime template with dojang (#9450)
- render get_trusted_types_policy with dojang - render global with dojang - render has_own_property with dojang - render rspack_version with dojang
- Loading branch information
1 parent
2d10e9a
commit ab8f3fe
Showing
26 changed files
with
113 additions
and
125 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 5 additions & 5 deletions
10
...odule/runtime/get_trusted_types_policy.js → ...dule/runtime/get_trusted_types_policy.ejs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
crates/rspack_plugin_runtime/src/runtime_module/runtime/get_version.ejs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<%- RSPACK_VERSION %> = <%- returningFunction(_version, "") %> |
3 changes: 0 additions & 3 deletions
3
crates/rspack_plugin_runtime/src/runtime_module/runtime/get_version.js
This file was deleted.
Oops, something went wrong.
4 changes: 2 additions & 2 deletions
4
...time/src/runtime_module/runtime/global.js → ...ime/src/runtime_module/runtime/global.ejs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
__webpack_require__.g = (function () { | ||
<%- GLOBAL %> = (<%- basicFunction("") %> { | ||
if (typeof globalThis === 'object') return globalThis; | ||
try { | ||
return this || new Function('return this')(); | ||
} catch (e) { | ||
if (typeof window === 'object') return window; | ||
} | ||
})(); | ||
})(); |
1 change: 1 addition & 0 deletions
1
crates/rspack_plugin_runtime/src/runtime_module/runtime/has_own_property.ejs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<%- HAS_OWN_PROPERTY %> = <%- returningFunction("Object.prototype.hasOwnProperty.call(obj, prop)", "obj, prop") %> |
3 changes: 0 additions & 3 deletions
3
crates/rspack_plugin_runtime/src/runtime_module/runtime/has_own_property.js
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
ab8f3fe
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
📝 Benchmark detail: Open
ab8f3fe
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
📝 Ecosystem CI detail: Open