@modern-js/module-tools-docs 2.2.1-beta.1 → 2.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (160) hide show
  1. package/docs/en/api/plugin-api/plugin-hooks.md +2 -10
  2. package/docs/en/guide/advance/in-depth-about-dev-command.md +0 -9
  3. package/docs/en/guide/basic/command-preview.md +1 -1
  4. package/docs/en/guide/basic/using-storybook.mdx +28 -6
  5. package/docs/en/guide/intro/getting-started.md +1 -1
  6. package/docs/en/index.md +14 -8
  7. package/docs/en/plugins/guide/getting-started.mdx +1 -1
  8. package/docs/zh/api/plugin-api/plugin-hooks.md +2 -10
  9. package/docs/zh/guide/advance/in-depth-about-dev-command.md +0 -8
  10. package/docs/zh/guide/basic/command-preview.md +1 -1
  11. package/docs/zh/guide/basic/using-storybook.mdx +28 -5
  12. package/docs/zh/index.md +16 -10
  13. package/docs/zh/plugins/guide/getting-started.mdx +1 -1
  14. package/modern.config.ts +4 -6
  15. package/package.json +4 -4
  16. package/doc_build/html/main/index.html +0 -16
  17. package/doc_build/route.json +0 -10
  18. package/doc_build/static/css/main.css +0 -2977
  19. package/doc_build/static/css/main.css.map +0 -1
  20. package/doc_build/static/css/vendors-node_modules_pnpm_remix-run_router_1_2_0_node_modules_remix-run_router_dist_router_js-9d5e9c.css +0 -68
  21. package/doc_build/static/css/vendors-node_modules_pnpm_remix-run_router_1_2_0_node_modules_remix-run_router_dist_router_js-9d5e9c.css.map +0 -1
  22. package/doc_build/static/js/async/en_api_config_build-config.js +0 -8406
  23. package/doc_build/static/js/async/en_api_config_build-config.js.map +0 -1
  24. package/doc_build/static/js/async/en_api_config_build-preset.js +0 -7865
  25. package/doc_build/static/js/async/en_api_config_build-preset.js.map +0 -1
  26. package/doc_build/static/js/async/en_api_config_design-system.js +0 -47805
  27. package/doc_build/static/js/async/en_api_config_design-system.js.map +0 -1
  28. package/doc_build/static/js/async/en_api_config_plugins.js +0 -1488
  29. package/doc_build/static/js/async/en_api_config_plugins.js.map +0 -1
  30. package/doc_build/static/js/async/en_api_config_testing.js +0 -2139
  31. package/doc_build/static/js/async/en_api_config_testing.js.map +0 -1
  32. package/doc_build/static/js/async/en_api_index.js +0 -51
  33. package/doc_build/static/js/async/en_api_index.js.map +0 -1
  34. package/doc_build/static/js/async/en_api_plugin-api_plugin-hooks.js +0 -14360
  35. package/doc_build/static/js/async/en_api_plugin-api_plugin-hooks.js.map +0 -1
  36. package/doc_build/static/js/async/en_guide_advance_asset.js +0 -3972
  37. package/doc_build/static/js/async/en_guide_advance_asset.js.map +0 -1
  38. package/doc_build/static/js/async/en_guide_advance_build-umd.js +0 -9857
  39. package/doc_build/static/js/async/en_guide_advance_build-umd.js.map +0 -1
  40. package/doc_build/static/js/async/en_guide_advance_copy.js +0 -6541
  41. package/doc_build/static/js/async/en_guide_advance_copy.js.map +0 -1
  42. package/doc_build/static/js/async/en_guide_advance_external-dependency.js +0 -3806
  43. package/doc_build/static/js/async/en_guide_advance_external-dependency.js.map +0 -1
  44. package/doc_build/static/js/async/en_guide_advance_in-depth-about-build.js +0 -5304
  45. package/doc_build/static/js/async/en_guide_advance_in-depth-about-build.js.map +0 -1
  46. package/doc_build/static/js/async/en_guide_advance_in-depth-about-dev-command.js +0 -2526
  47. package/doc_build/static/js/async/en_guide_advance_in-depth-about-dev-command.js.map +0 -1
  48. package/doc_build/static/js/async/en_guide_advance_theme-config.js +0 -2486
  49. package/doc_build/static/js/async/en_guide_advance_theme-config.js.map +0 -1
  50. package/doc_build/static/js/async/en_guide_basic_before-getting-started.js +0 -3720
  51. package/doc_build/static/js/async/en_guide_basic_before-getting-started.js.map +0 -1
  52. package/doc_build/static/js/async/en_guide_basic_command-preview.js +0 -3973
  53. package/doc_build/static/js/async/en_guide_basic_command-preview.js.map +0 -1
  54. package/doc_build/static/js/async/en_guide_basic_modify-output-product.js +0 -3137
  55. package/doc_build/static/js/async/en_guide_basic_modify-output-product.js.map +0 -1
  56. package/doc_build/static/js/async/en_guide_basic_publish-your-project.js +0 -2180
  57. package/doc_build/static/js/async/en_guide_basic_publish-your-project.js.map +0 -1
  58. package/doc_build/static/js/async/en_guide_basic_test-your-project.js +0 -3887
  59. package/doc_build/static/js/async/en_guide_basic_test-your-project.js.map +0 -1
  60. package/doc_build/static/js/async/en_guide_basic_use-micro-generator.js +0 -2973
  61. package/doc_build/static/js/async/en_guide_basic_use-micro-generator.js.map +0 -1
  62. package/doc_build/static/js/async/en_guide_basic_using-storybook.js +0 -4723
  63. package/doc_build/static/js/async/en_guide_basic_using-storybook.js.map +0 -1
  64. package/doc_build/static/js/async/en_guide_best-practices_components.js +0 -21400
  65. package/doc_build/static/js/async/en_guide_best-practices_components.js.map +0 -1
  66. package/doc_build/static/js/async/en_guide_intro_getting-started.js +0 -2149
  67. package/doc_build/static/js/async/en_guide_intro_getting-started.js.map +0 -1
  68. package/doc_build/static/js/async/en_guide_intro_welcome.js +0 -162
  69. package/doc_build/static/js/async/en_guide_intro_welcome.js.map +0 -1
  70. package/doc_build/static/js/async/en_guide_intro_why-module-engineering-solution.js +0 -96
  71. package/doc_build/static/js/async/en_guide_intro_why-module-engineering-solution.js.map +0 -1
  72. package/doc_build/static/js/async/en_index.js +0 -81
  73. package/doc_build/static/js/async/en_index.js.map +0 -1
  74. package/doc_build/static/js/async/en_plugins_guide_getting-started.js +0 -2556
  75. package/doc_build/static/js/async/en_plugins_guide_getting-started.js.map +0 -1
  76. package/doc_build/static/js/async/en_plugins_guide_plugin-object.js +0 -4173
  77. package/doc_build/static/js/async/en_plugins_guide_plugin-object.js.map +0 -1
  78. package/doc_build/static/js/async/en_plugins_guide_setup-function.js +0 -3815
  79. package/doc_build/static/js/async/en_plugins_guide_setup-function.js.map +0 -1
  80. package/doc_build/static/js/async/en_plugins_official-list_overview.js +0 -66
  81. package/doc_build/static/js/async/en_plugins_official-list_overview.js.map +0 -1
  82. package/doc_build/static/js/async/packages_cli_doc-core_src_theme-default_components_Search_logic_search_ts.js +0 -246
  83. package/doc_build/static/js/async/packages_cli_doc-core_src_theme-default_components_Search_logic_search_ts.js.map +0 -1
  84. package/doc_build/static/js/async/vendors-node_modules_pnpm_code-hike_mdx_0_7_4_react_18_2_0_node_modules_code-hike_mdx_dist_co-06dd41.js +0 -6656
  85. package/doc_build/static/js/async/vendors-node_modules_pnpm_code-hike_mdx_0_7_4_react_18_2_0_node_modules_code-hike_mdx_dist_co-06dd41.js.map +0 -1
  86. package/doc_build/static/js/async/vendors-node_modules_pnpm_flexsearch_0_6_32_node_modules_flexsearch_dist_flexsearch_min_js.js +0 -54
  87. package/doc_build/static/js/async/vendors-node_modules_pnpm_flexsearch_0_6_32_node_modules_flexsearch_dist_flexsearch_min_js.js.map +0 -1
  88. package/doc_build/static/js/async/zh_api_config_build-config.js +0 -11354
  89. package/doc_build/static/js/async/zh_api_config_build-config.js.map +0 -1
  90. package/doc_build/static/js/async/zh_api_config_build-preset.js +0 -7867
  91. package/doc_build/static/js/async/zh_api_config_build-preset.js.map +0 -1
  92. package/doc_build/static/js/async/zh_api_config_design-system.js +0 -48712
  93. package/doc_build/static/js/async/zh_api_config_design-system.js.map +0 -1
  94. package/doc_build/static/js/async/zh_api_config_plugins.js +0 -1488
  95. package/doc_build/static/js/async/zh_api_config_plugins.js.map +0 -1
  96. package/doc_build/static/js/async/zh_api_config_testing.js +0 -2132
  97. package/doc_build/static/js/async/zh_api_config_testing.js.map +0 -1
  98. package/doc_build/static/js/async/zh_api_index.js +0 -52
  99. package/doc_build/static/js/async/zh_api_index.js.map +0 -1
  100. package/doc_build/static/js/async/zh_api_plugin-api_plugin-hooks.js +0 -14392
  101. package/doc_build/static/js/async/zh_api_plugin-api_plugin-hooks.js.map +0 -1
  102. package/doc_build/static/js/async/zh_guide_advance_asset.js +0 -3972
  103. package/doc_build/static/js/async/zh_guide_advance_asset.js.map +0 -1
  104. package/doc_build/static/js/async/zh_guide_advance_build-umd.js +0 -9859
  105. package/doc_build/static/js/async/zh_guide_advance_build-umd.js.map +0 -1
  106. package/doc_build/static/js/async/zh_guide_advance_copy.js +0 -6541
  107. package/doc_build/static/js/async/zh_guide_advance_copy.js.map +0 -1
  108. package/doc_build/static/js/async/zh_guide_advance_external-dependency.js +0 -3808
  109. package/doc_build/static/js/async/zh_guide_advance_external-dependency.js.map +0 -1
  110. package/doc_build/static/js/async/zh_guide_advance_in-depth-about-build.js +0 -5304
  111. package/doc_build/static/js/async/zh_guide_advance_in-depth-about-build.js.map +0 -1
  112. package/doc_build/static/js/async/zh_guide_advance_in-depth-about-dev-command.js +0 -2526
  113. package/doc_build/static/js/async/zh_guide_advance_in-depth-about-dev-command.js.map +0 -1
  114. package/doc_build/static/js/async/zh_guide_advance_theme-config.js +0 -2477
  115. package/doc_build/static/js/async/zh_guide_advance_theme-config.js.map +0 -1
  116. package/doc_build/static/js/async/zh_guide_basic_before-getting-started.js +0 -3711
  117. package/doc_build/static/js/async/zh_guide_basic_before-getting-started.js.map +0 -1
  118. package/doc_build/static/js/async/zh_guide_basic_command-preview.js +0 -3805
  119. package/doc_build/static/js/async/zh_guide_basic_command-preview.js.map +0 -1
  120. package/doc_build/static/js/async/zh_guide_basic_modify-output-product.js +0 -3142
  121. package/doc_build/static/js/async/zh_guide_basic_modify-output-product.js.map +0 -1
  122. package/doc_build/static/js/async/zh_guide_basic_publish-your-project.js +0 -2241
  123. package/doc_build/static/js/async/zh_guide_basic_publish-your-project.js.map +0 -1
  124. package/doc_build/static/js/async/zh_guide_basic_test-your-project.js +0 -4286
  125. package/doc_build/static/js/async/zh_guide_basic_test-your-project.js.map +0 -1
  126. package/doc_build/static/js/async/zh_guide_basic_use-micro-generator.js +0 -2979
  127. package/doc_build/static/js/async/zh_guide_basic_use-micro-generator.js.map +0 -1
  128. package/doc_build/static/js/async/zh_guide_basic_using-storybook.js +0 -4760
  129. package/doc_build/static/js/async/zh_guide_basic_using-storybook.js.map +0 -1
  130. package/doc_build/static/js/async/zh_guide_best-practices_components.js +0 -21100
  131. package/doc_build/static/js/async/zh_guide_best-practices_components.js.map +0 -1
  132. package/doc_build/static/js/async/zh_guide_intro_getting-started.js +0 -2031
  133. package/doc_build/static/js/async/zh_guide_intro_getting-started.js.map +0 -1
  134. package/doc_build/static/js/async/zh_guide_intro_welcome.js +0 -162
  135. package/doc_build/static/js/async/zh_guide_intro_welcome.js.map +0 -1
  136. package/doc_build/static/js/async/zh_guide_intro_why-module-engineering-solution.js +0 -96
  137. package/doc_build/static/js/async/zh_guide_intro_why-module-engineering-solution.js.map +0 -1
  138. package/doc_build/static/js/async/zh_index.js +0 -81
  139. package/doc_build/static/js/async/zh_index.js.map +0 -1
  140. package/doc_build/static/js/async/zh_plugins_guide_getting-started.js +0 -2604
  141. package/doc_build/static/js/async/zh_plugins_guide_getting-started.js.map +0 -1
  142. package/doc_build/static/js/async/zh_plugins_guide_plugin-object.js +0 -4169
  143. package/doc_build/static/js/async/zh_plugins_guide_plugin-object.js.map +0 -1
  144. package/doc_build/static/js/async/zh_plugins_guide_setup-function.js +0 -3815
  145. package/doc_build/static/js/async/zh_plugins_guide_setup-function.js.map +0 -1
  146. package/doc_build/static/js/async/zh_plugins_official-list_overview.js +0 -66
  147. package/doc_build/static/js/async/zh_plugins_official-list_overview.js.map +0 -1
  148. package/doc_build/static/js/builder-runtime.js +0 -1375
  149. package/doc_build/static/js/builder-runtime.js.map +0 -1
  150. package/doc_build/static/js/lib-lodash.js +0 -4907
  151. package/doc_build/static/js/lib-lodash.js.map +0 -1
  152. package/doc_build/static/js/lib-polyfill.js +0 -11847
  153. package/doc_build/static/js/lib-polyfill.js.map +0 -1
  154. package/doc_build/static/js/lib-react.js +0 -39510
  155. package/doc_build/static/js/lib-react.js.map +0 -1
  156. package/doc_build/static/js/main.js +0 -8610
  157. package/doc_build/static/js/main.js.map +0 -1
  158. package/doc_build/static/js/vendors-node_modules_pnpm_remix-run_router_1_2_0_node_modules_remix-run_router_dist_router_js-9d5e9c.js +0 -7328
  159. package/doc_build/static/js/vendors-node_modules_pnpm_remix-run_router_1_2_0_node_modules_remix-run_router_dist_router_js-9d5e9c.js.map +0 -1
  160. package/doc_build/static/search_index.json +0 -1
@@ -1,3972 +0,0 @@
1
- "use strict";
2
- (self["webpackChunk_modern_js_module_tools_docs"] = self["webpackChunk_modern_js_module_tools_docs"] || []).push([["zh_guide_advance_asset"],{
3
-
4
- /***/ "./docs/zh/guide/advance/asset.mdx":
5
- /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
6
-
7
- __webpack_require__.r(__webpack_exports__);
8
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
9
- /* harmony export */ "CH": function() { return /* binding */ CH; },
10
- /* harmony export */ "chCodeConfig": function() { return /* binding */ chCodeConfig; },
11
- /* harmony export */ "content": function() { return /* binding */ content; },
12
- /* harmony export */ "frontmatter": function() { return /* binding */ frontmatter; },
13
- /* harmony export */ "title": function() { return /* binding */ title; },
14
- /* harmony export */ "toc": function() { return /* binding */ toc; }
15
- /* harmony export */ });
16
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("../../node_modules/.pnpm/react@18.2.0/node_modules/react/jsx-runtime.js");
17
- /* harmony import */ var _code_hike_mdx_dist_components_cjs_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("../../node_modules/.pnpm/@code-hike+mdx@0.7.4_react@18.2.0/node_modules/@code-hike/mdx/dist/components.esm.mjs");
18
- /*@jsxRuntime automatic @jsxImportSource react*/
19
-
20
-
21
- const CH = {
22
- annotations: _code_hike_mdx_dist_components_cjs_js__WEBPACK_IMPORTED_MODULE_1__.annotations,
23
- Spotlight: _code_hike_mdx_dist_components_cjs_js__WEBPACK_IMPORTED_MODULE_1__.Spotlight,
24
- CodeSlot: _code_hike_mdx_dist_components_cjs_js__WEBPACK_IMPORTED_MODULE_1__.CodeSlot,
25
- Code: _code_hike_mdx_dist_components_cjs_js__WEBPACK_IMPORTED_MODULE_1__.Code
26
- };
27
- const chCodeConfig = {
28
- "staticMediaQuery": "not screen, (max-width: 768px)",
29
- "theme": {
30
- "name": "nord",
31
- "type": "dark",
32
- "semanticHighlighting": true,
33
- "colors": {
34
- "focusBorder": "#3b4252",
35
- "foreground": "#d8dee9",
36
- "activityBar.background": "#2e3440",
37
- "activityBar.dropBackground": "#3b4252",
38
- "activityBar.foreground": "#d8dee9",
39
- "activityBar.activeBorder": "#88c0d0",
40
- "activityBar.activeBackground": "#3b4252",
41
- "activityBarBadge.background": "#88c0d0",
42
- "activityBarBadge.foreground": "#2e3440",
43
- "badge.foreground": "#2e3440",
44
- "badge.background": "#88c0d0",
45
- "button.background": "#88c0d0ee",
46
- "button.foreground": "#2e3440",
47
- "button.hoverBackground": "#88c0d0",
48
- "button.secondaryBackground": "#434c5e",
49
- "button.secondaryForeground": "#d8dee9",
50
- "button.secondaryHoverBackground": "#4c566a",
51
- "charts.red": "#bf616a",
52
- "charts.blue": "#81a1c1",
53
- "charts.yellow": "#ebcb8b",
54
- "charts.orange": "#d08770",
55
- "charts.green": "#a3be8c",
56
- "charts.purple": "#b48ead",
57
- "charts.foreground": "#d8dee9",
58
- "charts.lines": "#88c0d0",
59
- "debugConsole.infoForeground": "#88c0d0",
60
- "debugConsole.warningForeground": "#ebcb8b",
61
- "debugConsole.errorForeground": "#bf616a",
62
- "debugConsole.sourceForeground": "#616e88",
63
- "debugConsoleInputIcon.foreground": "#81a1c1",
64
- "debugExceptionWidget.background": "#4c566a",
65
- "debugExceptionWidget.border": "#2e3440",
66
- "debugToolBar.background": "#3b4252",
67
- "descriptionForeground": "#d8dee9e6",
68
- "diffEditor.insertedTextBackground": "#81a1c133",
69
- "diffEditor.removedTextBackground": "#bf616a4d",
70
- "dropdown.background": "#3b4252",
71
- "dropdown.border": "#3b4252",
72
- "dropdown.foreground": "#d8dee9",
73
- "editorActiveLineNumber.foreground": "#d8dee9cc",
74
- "editorCursor.foreground": "#d8dee9",
75
- "editorHint.border": "#ebcb8b00",
76
- "editorHint.foreground": "#ebcb8b",
77
- "editorIndentGuide.background": "#434c5eb3",
78
- "editorIndentGuide.activeBackground": "#4c566a",
79
- "editorInlayHint.background": "#434c5e",
80
- "editorInlayHint.foreground": "#d8dee9",
81
- "editorLineNumber.foreground": "#4c566a",
82
- "editorLineNumber.activeForeground": "#d8dee9",
83
- "editorWhitespace.foreground": "#4c566ab3",
84
- "editorWidget.background": "#2e3440",
85
- "editorWidget.border": "#3b4252",
86
- "editor.background": "#2e3440",
87
- "editor.foreground": "#d8dee9",
88
- "editor.hoverHighlightBackground": "#3b4252",
89
- "editor.findMatchBackground": "#88c0d066",
90
- "editor.findMatchHighlightBackground": "#88c0d033",
91
- "editor.findRangeHighlightBackground": "#88c0d033",
92
- "editor.lineHighlightBackground": "#3b4252",
93
- "editor.lineHighlightBorder": "#3b4252",
94
- "editor.inactiveSelectionBackground": "#434c5ecc",
95
- "editor.inlineValuesBackground": "#4c566a",
96
- "editor.inlineValuesForeground": "#eceff4",
97
- "editor.selectionBackground": "#434c5ecc",
98
- "editor.selectionHighlightBackground": "#434c5ecc",
99
- "editor.rangeHighlightBackground": "#434c5e52",
100
- "editor.wordHighlightBackground": "#81a1c166",
101
- "editor.wordHighlightStrongBackground": "#81a1c199",
102
- "editor.stackFrameHighlightBackground": "#5e81ac",
103
- "editor.focusedStackFrameHighlightBackground": "#5e81ac",
104
- "editorError.foreground": "#bf616a",
105
- "editorError.border": "#bf616a00",
106
- "editorWarning.foreground": "#ebcb8b",
107
- "editorWarning.border": "#ebcb8b00",
108
- "editorBracketMatch.background": "#2e344000",
109
- "editorBracketMatch.border": "#88c0d0",
110
- "editorBracketHighlight.foreground1": "#8fbcbb",
111
- "editorBracketHighlight.foreground2": "#88c0d0",
112
- "editorBracketHighlight.foreground3": "#81a1c1",
113
- "editorBracketHighlight.foreground4": "#5e81ac",
114
- "editorBracketHighlight.foreground5": "#8fbcbb",
115
- "editorBracketHighlight.foreground6": "#88c0d0",
116
- "editorBracketHighlight.unexpectedBracket.foreground": "#bf616a",
117
- "editorCodeLens.foreground": "#4c566a",
118
- "editorGroup.background": "#2e3440",
119
- "editorGroup.border": "#3b425201",
120
- "editorGroup.dropBackground": "#3b425299",
121
- "editorGroupHeader.border": "#3b425200",
122
- "editorGroupHeader.noTabsBackground": "#2e3440",
123
- "editorGroupHeader.tabsBackground": "#2e3440",
124
- "editorGroupHeader.tabsBorder": "#3b425200",
125
- "editorGutter.background": "#2e3440",
126
- "editorGutter.modifiedBackground": "#ebcb8b",
127
- "editorGutter.addedBackground": "#a3be8c",
128
- "editorGutter.deletedBackground": "#bf616a",
129
- "editorHoverWidget.background": "#3b4252",
130
- "editorHoverWidget.border": "#3b4252",
131
- "editorLink.activeForeground": "#88c0d0",
132
- "editorMarkerNavigation.background": "#5e81acc0",
133
- "editorMarkerNavigationError.background": "#bf616ac0",
134
- "editorMarkerNavigationWarning.background": "#ebcb8bc0",
135
- "editorOverviewRuler.border": "#3b4252",
136
- "editorOverviewRuler.currentContentForeground": "#3b4252",
137
- "editorOverviewRuler.incomingContentForeground": "#3b4252",
138
- "editorOverviewRuler.findMatchForeground": "#88c0d066",
139
- "editorOverviewRuler.rangeHighlightForeground": "#88c0d066",
140
- "editorOverviewRuler.selectionHighlightForeground": "#88c0d066",
141
- "editorOverviewRuler.wordHighlightForeground": "#88c0d066",
142
- "editorOverviewRuler.wordHighlightStrongForeground": "#88c0d066",
143
- "editorOverviewRuler.modifiedForeground": "#ebcb8b",
144
- "editorOverviewRuler.addedForeground": "#a3be8c",
145
- "editorOverviewRuler.deletedForeground": "#bf616a",
146
- "editorOverviewRuler.errorForeground": "#bf616a",
147
- "editorOverviewRuler.warningForeground": "#ebcb8b",
148
- "editorOverviewRuler.infoForeground": "#81a1c1",
149
- "editorRuler.foreground": "#434c5e",
150
- "editorSuggestWidget.background": "#2e3440",
151
- "editorSuggestWidget.border": "#3b4252",
152
- "editorSuggestWidget.foreground": "#d8dee9",
153
- "editorSuggestWidget.focusHighlightForeground": "#88c0d0",
154
- "editorSuggestWidget.highlightForeground": "#88c0d0",
155
- "editorSuggestWidget.selectedBackground": "#434c5e",
156
- "editorSuggestWidget.selectedForeground": "#d8dee9",
157
- "extensionButton.prominentForeground": "#d8dee9",
158
- "extensionButton.prominentBackground": "#434c5e",
159
- "extensionButton.prominentHoverBackground": "#4c566a",
160
- "errorForeground": "#bf616a",
161
- "gitDecoration.modifiedResourceForeground": "#ebcb8b",
162
- "gitDecoration.deletedResourceForeground": "#bf616a",
163
- "gitDecoration.untrackedResourceForeground": "#a3be8c",
164
- "gitDecoration.ignoredResourceForeground": "#d8dee966",
165
- "gitDecoration.conflictingResourceForeground": "#5e81ac",
166
- "gitDecoration.submoduleResourceForeground": "#8fbcbb",
167
- "gitDecoration.stageDeletedResourceForeground": "#bf616a",
168
- "gitDecoration.stageModifiedResourceForeground": "#ebcb8b",
169
- "input.background": "#3b4252",
170
- "input.foreground": "#d8dee9",
171
- "input.placeholderForeground": "#d8dee999",
172
- "input.border": "#3b4252",
173
- "inputOption.activeBackground": "#5e81ac",
174
- "inputOption.activeBorder": "#5e81ac",
175
- "inputOption.activeForeground": "#eceff4",
176
- "inputValidation.errorBackground": "#bf616a",
177
- "inputValidation.errorBorder": "#bf616a",
178
- "inputValidation.infoBackground": "#81a1c1",
179
- "inputValidation.infoBorder": "#81a1c1",
180
- "inputValidation.warningBackground": "#d08770",
181
- "inputValidation.warningBorder": "#d08770",
182
- "keybindingLabel.background": "#4c566a",
183
- "keybindingLabel.border": "#4c566a",
184
- "keybindingLabel.bottomBorder": "#4c566a",
185
- "keybindingLabel.foreground": "#d8dee9",
186
- "list.activeSelectionBackground": "#88c0d0",
187
- "list.activeSelectionForeground": "#2e3440",
188
- "list.inactiveSelectionBackground": "#434c5e",
189
- "list.inactiveSelectionForeground": "#d8dee9",
190
- "list.inactiveFocusBackground": "#434c5ecc",
191
- "list.hoverForeground": "#eceff4",
192
- "list.focusForeground": "#d8dee9",
193
- "list.focusBackground": "#88c0d099",
194
- "list.focusHighlightForeground": "#eceff4",
195
- "list.hoverBackground": "#3b4252",
196
- "list.dropBackground": "#88c0d099",
197
- "list.highlightForeground": "#88c0d0",
198
- "list.errorForeground": "#bf616a",
199
- "list.warningForeground": "#ebcb8b",
200
- "merge.currentHeaderBackground": "#81a1c166",
201
- "merge.currentContentBackground": "#81a1c14d",
202
- "merge.incomingHeaderBackground": "#8fbcbb66",
203
- "merge.incomingContentBackground": "#8fbcbb4d",
204
- "merge.border": "#3b425200",
205
- "minimap.background": "#2e3440",
206
- "minimap.errorHighlight": "#bf616acc",
207
- "minimap.findMatchHighlight": "#88c0d0",
208
- "minimap.selectionHighlight": "#88c0d0cc",
209
- "minimap.warningHighlight": "#ebcb8bcc",
210
- "minimapGutter.addedBackground": "#a3be8c",
211
- "minimapGutter.deletedBackground": "#bf616a",
212
- "minimapGutter.modifiedBackground": "#ebcb8b",
213
- "minimapSlider.activeBackground": "#434c5eaa",
214
- "minimapSlider.background": "#434c5e99",
215
- "minimapSlider.hoverBackground": "#434c5eaa",
216
- "notification.background": "#3b4252",
217
- "notification.buttonBackground": "#434c5e",
218
- "notification.buttonForeground": "#d8dee9",
219
- "notification.buttonHoverBackground": "#4c566a",
220
- "notification.errorBackground": "#bf616a",
221
- "notification.errorForeground": "#2e3440",
222
- "notification.foreground": "#d8dee9",
223
- "notification.infoBackground": "#88c0d0",
224
- "notification.infoForeground": "#2e3440",
225
- "notification.warningBackground": "#ebcb8b",
226
- "notification.warningForeground": "#2e3440",
227
- "notificationCenter.border": "#3b425200",
228
- "notificationCenterHeader.background": "#2e3440",
229
- "notificationCenterHeader.foreground": "#88c0d0",
230
- "notificationLink.foreground": "#88c0d0",
231
- "notifications.background": "#3b4252",
232
- "notifications.border": "#2e3440",
233
- "notifications.foreground": "#d8dee9",
234
- "notificationToast.border": "#3b425200",
235
- "panel.background": "#2e3440",
236
- "panel.border": "#3b4252",
237
- "panelTitle.activeBorder": "#88c0d000",
238
- "panelTitle.activeForeground": "#88c0d0",
239
- "panelTitle.inactiveForeground": "#d8dee9",
240
- "peekView.border": "#4c566a",
241
- "peekViewEditor.background": "#2e3440",
242
- "peekViewEditorGutter.background": "#2e3440",
243
- "peekViewEditor.matchHighlightBackground": "#88c0d04d",
244
- "peekViewResult.background": "#2e3440",
245
- "peekViewResult.fileForeground": "#88c0d0",
246
- "peekViewResult.lineForeground": "#d8dee966",
247
- "peekViewResult.matchHighlightBackground": "#88c0d0cc",
248
- "peekViewResult.selectionBackground": "#434c5e",
249
- "peekViewResult.selectionForeground": "#d8dee9",
250
- "peekViewTitle.background": "#3b4252",
251
- "peekViewTitleDescription.foreground": "#d8dee9",
252
- "peekViewTitleLabel.foreground": "#88c0d0",
253
- "pickerGroup.border": "#3b4252",
254
- "pickerGroup.foreground": "#88c0d0",
255
- "progressBar.background": "#88c0d0",
256
- "quickInputList.focusBackground": "#88c0d0",
257
- "quickInputList.focusForeground": "#2e3440",
258
- "sash.hoverBorder": "#88c0d0",
259
- "scrollbar.shadow": "#00000066",
260
- "scrollbarSlider.activeBackground": "#434c5eaa",
261
- "scrollbarSlider.background": "#434c5e99",
262
- "scrollbarSlider.hoverBackground": "#434c5eaa",
263
- "selection.background": "#88c0d099",
264
- "sideBar.background": "#2e3440",
265
- "sideBar.foreground": "#d8dee9",
266
- "sideBar.border": "#3b4252",
267
- "sideBarSectionHeader.background": "#3b4252",
268
- "sideBarSectionHeader.foreground": "#d8dee9",
269
- "sideBarTitle.foreground": "#d8dee9",
270
- "statusBar.background": "#3b4252",
271
- "statusBar.debuggingBackground": "#5e81ac",
272
- "statusBar.debuggingForeground": "#d8dee9",
273
- "statusBar.noFolderForeground": "#d8dee9",
274
- "statusBar.noFolderBackground": "#3b4252",
275
- "statusBar.foreground": "#d8dee9",
276
- "statusBarItem.activeBackground": "#4c566a",
277
- "statusBarItem.hoverBackground": "#434c5e",
278
- "statusBarItem.prominentBackground": "#3b4252",
279
- "statusBarItem.prominentHoverBackground": "#434c5e",
280
- "statusBarItem.errorBackground": "#3b4252",
281
- "statusBarItem.errorForeground": "#bf616a",
282
- "statusBarItem.warningBackground": "#ebcb8b",
283
- "statusBarItem.warningForeground": "#2e3440",
284
- "statusBar.border": "#3b425200",
285
- "tab.activeBackground": "#3b4252",
286
- "tab.activeForeground": "#d8dee9",
287
- "tab.border": "#3b425200",
288
- "tab.activeBorder": "#88c0d000",
289
- "tab.unfocusedActiveBorder": "#88c0d000",
290
- "tab.inactiveBackground": "#2e3440",
291
- "tab.inactiveForeground": "#d8dee966",
292
- "tab.unfocusedActiveForeground": "#d8dee999",
293
- "tab.unfocusedInactiveForeground": "#d8dee966",
294
- "tab.hoverBackground": "#3b4252cc",
295
- "tab.unfocusedHoverBackground": "#3b4252b3",
296
- "tab.hoverBorder": "#88c0d000",
297
- "tab.unfocusedHoverBorder": "#88c0d000",
298
- "tab.activeBorderTop": "#88c0d000",
299
- "tab.unfocusedActiveBorderTop": "#88c0d000",
300
- "tab.lastPinnedBorder": "#4c566a",
301
- "terminal.background": "#2e3440",
302
- "terminal.foreground": "#d8dee9",
303
- "terminal.ansiBlack": "#3b4252",
304
- "terminal.ansiRed": "#bf616a",
305
- "terminal.ansiGreen": "#a3be8c",
306
- "terminal.ansiYellow": "#ebcb8b",
307
- "terminal.ansiBlue": "#81a1c1",
308
- "terminal.ansiMagenta": "#b48ead",
309
- "terminal.ansiCyan": "#88c0d0",
310
- "terminal.ansiWhite": "#e5e9f0",
311
- "terminal.ansiBrightBlack": "#4c566a",
312
- "terminal.ansiBrightRed": "#bf616a",
313
- "terminal.ansiBrightGreen": "#a3be8c",
314
- "terminal.ansiBrightYellow": "#ebcb8b",
315
- "terminal.ansiBrightBlue": "#81a1c1",
316
- "terminal.ansiBrightMagenta": "#b48ead",
317
- "terminal.ansiBrightCyan": "#8fbcbb",
318
- "terminal.ansiBrightWhite": "#eceff4",
319
- "terminal.tab.activeBorder": "#88c0d0",
320
- "textBlockQuote.background": "#3b4252",
321
- "textBlockQuote.border": "#81a1c1",
322
- "textCodeBlock.background": "#4c566a",
323
- "textLink.activeForeground": "#88c0d0",
324
- "textLink.foreground": "#88c0d0",
325
- "textPreformat.foreground": "#8fbcbb",
326
- "textSeparator.foreground": "#eceff4",
327
- "titleBar.activeBackground": "#2e3440",
328
- "titleBar.activeForeground": "#d8dee9",
329
- "titleBar.border": "#2e344000",
330
- "titleBar.inactiveBackground": "#2e3440",
331
- "titleBar.inactiveForeground": "#d8dee966",
332
- "tree.indentGuidesStroke": "#616e88",
333
- "walkThrough.embeddedEditorBackground": "#2e3440",
334
- "welcomePage.buttonBackground": "#434c5e",
335
- "welcomePage.buttonHoverBackground": "#4c566a",
336
- "widget.shadow": "#00000066"
337
- },
338
- "tokenColors": [{
339
- "settings": {
340
- "foreground": "#d8dee9ff",
341
- "background": "#2e3440ff"
342
- }
343
- }, {
344
- "scope": "emphasis",
345
- "settings": {
346
- "fontStyle": "italic"
347
- }
348
- }, {
349
- "scope": "strong",
350
- "settings": {
351
- "fontStyle": "bold"
352
- }
353
- }, {
354
- "name": "Comment",
355
- "scope": "comment",
356
- "settings": {
357
- "foreground": "#616E88"
358
- }
359
- }, {
360
- "name": "Constant Character",
361
- "scope": "constant.character",
362
- "settings": {
363
- "foreground": "#EBCB8B"
364
- }
365
- }, {
366
- "name": "Constant Character Escape",
367
- "scope": "constant.character.escape",
368
- "settings": {
369
- "foreground": "#EBCB8B"
370
- }
371
- }, {
372
- "name": "Constant Language",
373
- "scope": "constant.language",
374
- "settings": {
375
- "foreground": "#81A1C1"
376
- }
377
- }, {
378
- "name": "Constant Numeric",
379
- "scope": "constant.numeric",
380
- "settings": {
381
- "foreground": "#B48EAD"
382
- }
383
- }, {
384
- "name": "Constant Regexp",
385
- "scope": "constant.regexp",
386
- "settings": {
387
- "foreground": "#EBCB8B"
388
- }
389
- }, {
390
- "name": "Entity Name Class/Type",
391
- "scope": ["entity.name.class", "entity.name.type.class"],
392
- "settings": {
393
- "foreground": "#8FBCBB"
394
- }
395
- }, {
396
- "name": "Entity Name Function",
397
- "scope": "entity.name.function",
398
- "settings": {
399
- "foreground": "#88C0D0"
400
- }
401
- }, {
402
- "name": "Entity Name Tag",
403
- "scope": "entity.name.tag",
404
- "settings": {
405
- "foreground": "#81A1C1"
406
- }
407
- }, {
408
- "name": "Entity Other Attribute Name",
409
- "scope": "entity.other.attribute-name",
410
- "settings": {
411
- "foreground": "#8FBCBB"
412
- }
413
- }, {
414
- "name": "Entity Other Inherited Class",
415
- "scope": "entity.other.inherited-class",
416
- "settings": {
417
- "fontStyle": "bold",
418
- "foreground": "#8FBCBB"
419
- }
420
- }, {
421
- "name": "Invalid Deprecated",
422
- "scope": "invalid.deprecated",
423
- "settings": {
424
- "foreground": "#D8DEE9",
425
- "background": "#EBCB8B"
426
- }
427
- }, {
428
- "name": "Invalid Illegal",
429
- "scope": "invalid.illegal",
430
- "settings": {
431
- "foreground": "#D8DEE9",
432
- "background": "#BF616A"
433
- }
434
- }, {
435
- "name": "Keyword",
436
- "scope": "keyword",
437
- "settings": {
438
- "foreground": "#81A1C1"
439
- }
440
- }, {
441
- "name": "Keyword Operator",
442
- "scope": "keyword.operator",
443
- "settings": {
444
- "foreground": "#81A1C1"
445
- }
446
- }, {
447
- "name": "Keyword Other New",
448
- "scope": "keyword.other.new",
449
- "settings": {
450
- "foreground": "#81A1C1"
451
- }
452
- }, {
453
- "name": "Markup Bold",
454
- "scope": "markup.bold",
455
- "settings": {
456
- "fontStyle": "bold"
457
- }
458
- }, {
459
- "name": "Markup Changed",
460
- "scope": "markup.changed",
461
- "settings": {
462
- "foreground": "#EBCB8B"
463
- }
464
- }, {
465
- "name": "Markup Deleted",
466
- "scope": "markup.deleted",
467
- "settings": {
468
- "foreground": "#BF616A"
469
- }
470
- }, {
471
- "name": "Markup Inserted",
472
- "scope": "markup.inserted",
473
- "settings": {
474
- "foreground": "#A3BE8C"
475
- }
476
- }, {
477
- "name": "Meta Preprocessor",
478
- "scope": "meta.preprocessor",
479
- "settings": {
480
- "foreground": "#5E81AC"
481
- }
482
- }, {
483
- "name": "Punctuation",
484
- "scope": "punctuation",
485
- "settings": {
486
- "foreground": "#ECEFF4"
487
- }
488
- }, {
489
- "name": "Punctuation Definition Parameters",
490
- "scope": ["punctuation.definition.method-parameters", "punctuation.definition.function-parameters", "punctuation.definition.parameters"],
491
- "settings": {
492
- "foreground": "#ECEFF4"
493
- }
494
- }, {
495
- "name": "Punctuation Definition Tag",
496
- "scope": "punctuation.definition.tag",
497
- "settings": {
498
- "foreground": "#81A1C1"
499
- }
500
- }, {
501
- "name": "Punctuation Definition Comment",
502
- "scope": ["punctuation.definition.comment", "punctuation.end.definition.comment", "punctuation.start.definition.comment"],
503
- "settings": {
504
- "foreground": "#616E88"
505
- }
506
- }, {
507
- "name": "Punctuation Section",
508
- "scope": "punctuation.section",
509
- "settings": {
510
- "foreground": "#ECEFF4"
511
- }
512
- }, {
513
- "name": "Punctuation Section Embedded",
514
- "scope": ["punctuation.section.embedded.begin", "punctuation.section.embedded.end"],
515
- "settings": {
516
- "foreground": "#81A1C1"
517
- }
518
- }, {
519
- "name": "Punctuation Terminator",
520
- "scope": "punctuation.terminator",
521
- "settings": {
522
- "foreground": "#81A1C1"
523
- }
524
- }, {
525
- "name": "Punctuation Variable",
526
- "scope": "punctuation.definition.variable",
527
- "settings": {
528
- "foreground": "#81A1C1"
529
- }
530
- }, {
531
- "name": "Storage",
532
- "scope": "storage",
533
- "settings": {
534
- "foreground": "#81A1C1"
535
- }
536
- }, {
537
- "name": "String",
538
- "scope": "string",
539
- "settings": {
540
- "foreground": "#A3BE8C"
541
- }
542
- }, {
543
- "name": "String Regexp",
544
- "scope": "string.regexp",
545
- "settings": {
546
- "foreground": "#EBCB8B"
547
- }
548
- }, {
549
- "name": "Support Class",
550
- "scope": "support.class",
551
- "settings": {
552
- "foreground": "#8FBCBB"
553
- }
554
- }, {
555
- "name": "Support Constant",
556
- "scope": "support.constant",
557
- "settings": {
558
- "foreground": "#81A1C1"
559
- }
560
- }, {
561
- "name": "Support Function",
562
- "scope": "support.function",
563
- "settings": {
564
- "foreground": "#88C0D0"
565
- }
566
- }, {
567
- "name": "Support Function Construct",
568
- "scope": "support.function.construct",
569
- "settings": {
570
- "foreground": "#81A1C1"
571
- }
572
- }, {
573
- "name": "Support Type",
574
- "scope": "support.type",
575
- "settings": {
576
- "foreground": "#8FBCBB"
577
- }
578
- }, {
579
- "name": "Support Type Exception",
580
- "scope": "support.type.exception",
581
- "settings": {
582
- "foreground": "#8FBCBB"
583
- }
584
- }, {
585
- "name": "Token Debug",
586
- "scope": "token.debug-token",
587
- "settings": {
588
- "foreground": "#b48ead"
589
- }
590
- }, {
591
- "name": "Token Error",
592
- "scope": "token.error-token",
593
- "settings": {
594
- "foreground": "#bf616a"
595
- }
596
- }, {
597
- "name": "Token Info",
598
- "scope": "token.info-token",
599
- "settings": {
600
- "foreground": "#88c0d0"
601
- }
602
- }, {
603
- "name": "Token Warning",
604
- "scope": "token.warn-token",
605
- "settings": {
606
- "foreground": "#ebcb8b"
607
- }
608
- }, {
609
- "name": "Variable",
610
- "scope": "variable.other",
611
- "settings": {
612
- "foreground": "#D8DEE9"
613
- }
614
- }, {
615
- "name": "Variable Language",
616
- "scope": "variable.language",
617
- "settings": {
618
- "foreground": "#81A1C1"
619
- }
620
- }, {
621
- "name": "Variable Parameter",
622
- "scope": "variable.parameter",
623
- "settings": {
624
- "foreground": "#D8DEE9"
625
- }
626
- }, {
627
- "name": "[C/CPP] Punctuation Separator Pointer-Access",
628
- "scope": "punctuation.separator.pointer-access.c",
629
- "settings": {
630
- "foreground": "#81A1C1"
631
- }
632
- }, {
633
- "name": "[C/CPP] Meta Preprocessor Include",
634
- "scope": ["source.c meta.preprocessor.include", "source.c string.quoted.other.lt-gt.include"],
635
- "settings": {
636
- "foreground": "#8FBCBB"
637
- }
638
- }, {
639
- "name": "[C/CPP] Conditional Directive",
640
- "scope": ["source.cpp keyword.control.directive.conditional", "source.cpp punctuation.definition.directive", "source.c keyword.control.directive.conditional", "source.c punctuation.definition.directive"],
641
- "settings": {
642
- "foreground": "#5E81AC",
643
- "fontStyle": "bold"
644
- }
645
- }, {
646
- "name": "[CSS] Constant Other Color RGB Value",
647
- "scope": "source.css constant.other.color.rgb-value",
648
- "settings": {
649
- "foreground": "#B48EAD"
650
- }
651
- }, {
652
- "name": "[CSS](Function) Meta Property-Value",
653
- "scope": "source.css meta.property-value",
654
- "settings": {
655
- "foreground": "#88C0D0"
656
- }
657
- }, {
658
- "name": "[CSS] Media Queries",
659
- "scope": ["source.css keyword.control.at-rule.media", "source.css keyword.control.at-rule.media punctuation.definition.keyword"],
660
- "settings": {
661
- "foreground": "#D08770"
662
- }
663
- }, {
664
- "name": "[CSS] Punctuation Definition Keyword",
665
- "scope": "source.css punctuation.definition.keyword",
666
- "settings": {
667
- "foreground": "#81A1C1"
668
- }
669
- }, {
670
- "name": "[CSS] Support Type Property Name",
671
- "scope": "source.css support.type.property-name",
672
- "settings": {
673
- "foreground": "#D8DEE9"
674
- }
675
- }, {
676
- "name": "[diff] Meta Range Context",
677
- "scope": "source.diff meta.diff.range.context",
678
- "settings": {
679
- "foreground": "#8FBCBB"
680
- }
681
- }, {
682
- "name": "[diff] Meta Header From-File",
683
- "scope": "source.diff meta.diff.header.from-file",
684
- "settings": {
685
- "foreground": "#8FBCBB"
686
- }
687
- }, {
688
- "name": "[diff] Punctuation Definition From-File",
689
- "scope": "source.diff punctuation.definition.from-file",
690
- "settings": {
691
- "foreground": "#8FBCBB"
692
- }
693
- }, {
694
- "name": "[diff] Punctuation Definition Range",
695
- "scope": "source.diff punctuation.definition.range",
696
- "settings": {
697
- "foreground": "#8FBCBB"
698
- }
699
- }, {
700
- "name": "[diff] Punctuation Definition Separator",
701
- "scope": "source.diff punctuation.definition.separator",
702
- "settings": {
703
- "foreground": "#81A1C1"
704
- }
705
- }, {
706
- "name": "[Elixir](JakeBecker.elixir-ls) module names",
707
- "scope": "entity.name.type.module.elixir",
708
- "settings": {
709
- "foreground": "#8FBCBB"
710
- }
711
- }, {
712
- "name": "[Elixir](JakeBecker.elixir-ls) module attributes",
713
- "scope": "variable.other.readwrite.module.elixir",
714
- "settings": {
715
- "foreground": "#D8DEE9",
716
- "fontStyle": "bold"
717
- }
718
- }, {
719
- "name": "[Elixir](JakeBecker.elixir-ls) atoms",
720
- "scope": "constant.other.symbol.elixir",
721
- "settings": {
722
- "foreground": "#D8DEE9",
723
- "fontStyle": "bold"
724
- }
725
- }, {
726
- "name": "[Elixir](JakeBecker.elixir-ls) modules",
727
- "scope": "variable.other.constant.elixir",
728
- "settings": {
729
- "foreground": "#8FBCBB"
730
- }
731
- }, {
732
- "name": "[Go] String Format Placeholder",
733
- "scope": "source.go constant.other.placeholder.go",
734
- "settings": {
735
- "foreground": "#EBCB8B"
736
- }
737
- }, {
738
- "name": "[Java](JavaDoc) Comment Block Documentation HTML Entities",
739
- "scope": "source.java comment.block.documentation.javadoc punctuation.definition.entity.html",
740
- "settings": {
741
- "foreground": "#81A1C1"
742
- }
743
- }, {
744
- "name": "[Java](JavaDoc) Constant Other",
745
- "scope": "source.java constant.other",
746
- "settings": {
747
- "foreground": "#D8DEE9"
748
- }
749
- }, {
750
- "name": "[Java](JavaDoc) Keyword Other Documentation",
751
- "scope": "source.java keyword.other.documentation",
752
- "settings": {
753
- "foreground": "#8FBCBB"
754
- }
755
- }, {
756
- "name": "[Java](JavaDoc) Keyword Other Documentation Author",
757
- "scope": "source.java keyword.other.documentation.author.javadoc",
758
- "settings": {
759
- "foreground": "#8FBCBB"
760
- }
761
- }, {
762
- "name": "[Java](JavaDoc) Keyword Other Documentation Directive/Custom",
763
- "scope": ["source.java keyword.other.documentation.directive", "source.java keyword.other.documentation.custom"],
764
- "settings": {
765
- "foreground": "#8FBCBB"
766
- }
767
- }, {
768
- "name": "[Java](JavaDoc) Keyword Other Documentation See",
769
- "scope": "source.java keyword.other.documentation.see.javadoc",
770
- "settings": {
771
- "foreground": "#8FBCBB"
772
- }
773
- }, {
774
- "name": "[Java] Meta Method-Call",
775
- "scope": "source.java meta.method-call meta.method",
776
- "settings": {
777
- "foreground": "#88C0D0"
778
- }
779
- }, {
780
- "name": "[Java](JavaDoc) Meta Tag Template Link",
781
- "scope": ["source.java meta.tag.template.link.javadoc", "source.java string.other.link.title.javadoc"],
782
- "settings": {
783
- "foreground": "#8FBCBB"
784
- }
785
- }, {
786
- "name": "[Java](JavaDoc) Meta Tag Template Value",
787
- "scope": "source.java meta.tag.template.value.javadoc",
788
- "settings": {
789
- "foreground": "#88C0D0"
790
- }
791
- }, {
792
- "name": "[Java](JavaDoc) Punctuation Definition Keyword",
793
- "scope": "source.java punctuation.definition.keyword.javadoc",
794
- "settings": {
795
- "foreground": "#8FBCBB"
796
- }
797
- }, {
798
- "name": "[Java](JavaDoc) Punctuation Definition Tag",
799
- "scope": ["source.java punctuation.definition.tag.begin.javadoc", "source.java punctuation.definition.tag.end.javadoc"],
800
- "settings": {
801
- "foreground": "#616E88"
802
- }
803
- }, {
804
- "name": "[Java] Storage Modifier Import",
805
- "scope": "source.java storage.modifier.import",
806
- "settings": {
807
- "foreground": "#8FBCBB"
808
- }
809
- }, {
810
- "name": "[Java] Storage Modifier Package",
811
- "scope": "source.java storage.modifier.package",
812
- "settings": {
813
- "foreground": "#8FBCBB"
814
- }
815
- }, {
816
- "name": "[Java] Storage Type",
817
- "scope": "source.java storage.type",
818
- "settings": {
819
- "foreground": "#8FBCBB"
820
- }
821
- }, {
822
- "name": "[Java] Storage Type Annotation",
823
- "scope": "source.java storage.type.annotation",
824
- "settings": {
825
- "foreground": "#D08770"
826
- }
827
- }, {
828
- "name": "[Java] Storage Type Generic",
829
- "scope": "source.java storage.type.generic",
830
- "settings": {
831
- "foreground": "#8FBCBB"
832
- }
833
- }, {
834
- "name": "[Java] Storage Type Primitive",
835
- "scope": "source.java storage.type.primitive",
836
- "settings": {
837
- "foreground": "#81A1C1"
838
- }
839
- }, {
840
- "name": "[JavaScript] Decorator",
841
- "scope": ["source.js punctuation.decorator", "source.js meta.decorator variable.other.readwrite", "source.js meta.decorator entity.name.function"],
842
- "settings": {
843
- "foreground": "#D08770"
844
- }
845
- }, {
846
- "name": "[JavaScript] Meta Object-Literal Key",
847
- "scope": "source.js meta.object-literal.key",
848
- "settings": {
849
- "foreground": "#88C0D0"
850
- }
851
- }, {
852
- "name": "[JavaScript](JSDoc) Storage Type Class",
853
- "scope": "source.js storage.type.class.jsdoc",
854
- "settings": {
855
- "foreground": "#8FBCBB"
856
- }
857
- }, {
858
- "name": "[JavaScript] String Template Literals Punctuation",
859
- "scope": ["source.js string.quoted.template punctuation.quasi.element.begin", "source.js string.quoted.template punctuation.quasi.element.end", "source.js string.template punctuation.definition.template-expression"],
860
- "settings": {
861
- "foreground": "#81A1C1"
862
- }
863
- }, {
864
- "name": "[JavaScript] Interpolated String Template Punctuation Functions",
865
- "scope": "source.js string.quoted.template meta.method-call.with-arguments",
866
- "settings": {
867
- "foreground": "#ECEFF4"
868
- }
869
- }, {
870
- "name": "[JavaScript] String Template Literal Variable",
871
- "scope": ["source.js string.template meta.template.expression support.variable.property", "source.js string.template meta.template.expression variable.other.object"],
872
- "settings": {
873
- "foreground": "#D8DEE9"
874
- }
875
- }, {
876
- "name": "[JavaScript] Support Type Primitive",
877
- "scope": "source.js support.type.primitive",
878
- "settings": {
879
- "foreground": "#81A1C1"
880
- }
881
- }, {
882
- "name": "[JavaScript] Variable Other Object",
883
- "scope": "source.js variable.other.object",
884
- "settings": {
885
- "foreground": "#D8DEE9"
886
- }
887
- }, {
888
- "name": "[JavaScript] Variable Other Read-Write Alias",
889
- "scope": "source.js variable.other.readwrite.alias",
890
- "settings": {
891
- "foreground": "#8FBCBB"
892
- }
893
- }, {
894
- "name": "[JavaScript] Parentheses in Template Strings",
895
- "scope": ["source.js meta.embedded.line meta.brace.square", "source.js meta.embedded.line meta.brace.round", "source.js string.quoted.template meta.brace.square", "source.js string.quoted.template meta.brace.round"],
896
- "settings": {
897
- "foreground": "#ECEFF4"
898
- }
899
- }, {
900
- "name": "[HTML] Constant Character Entity",
901
- "scope": "text.html.basic constant.character.entity.html",
902
- "settings": {
903
- "foreground": "#EBCB8B"
904
- }
905
- }, {
906
- "name": "[HTML] Constant Other Inline-Data",
907
- "scope": "text.html.basic constant.other.inline-data",
908
- "settings": {
909
- "foreground": "#D08770",
910
- "fontStyle": "italic"
911
- }
912
- }, {
913
- "name": "[HTML] Meta Tag SGML Doctype",
914
- "scope": "text.html.basic meta.tag.sgml.doctype",
915
- "settings": {
916
- "foreground": "#5E81AC"
917
- }
918
- }, {
919
- "name": "[HTML] Punctuation Definition Entity",
920
- "scope": "text.html.basic punctuation.definition.entity",
921
- "settings": {
922
- "foreground": "#81A1C1"
923
- }
924
- }, {
925
- "name": "[INI] Entity Name Section Group-Title",
926
- "scope": "source.properties entity.name.section.group-title.ini",
927
- "settings": {
928
- "foreground": "#88C0D0"
929
- }
930
- }, {
931
- "name": "[INI] Punctuation Separator Key-Value",
932
- "scope": "source.properties punctuation.separator.key-value.ini",
933
- "settings": {
934
- "foreground": "#81A1C1"
935
- }
936
- }, {
937
- "name": "[Markdown] Markup Fenced Code Block",
938
- "scope": ["text.html.markdown markup.fenced_code.block", "text.html.markdown markup.fenced_code.block punctuation.definition"],
939
- "settings": {
940
- "foreground": "#8FBCBB"
941
- }
942
- }, {
943
- "name": "[Markdown] Markup Heading",
944
- "scope": "markup.heading",
945
- "settings": {
946
- "foreground": "#88C0D0"
947
- }
948
- }, {
949
- "name": "[Markdown] Markup Inline",
950
- "scope": ["text.html.markdown markup.inline.raw", "text.html.markdown markup.inline.raw punctuation.definition.raw"],
951
- "settings": {
952
- "foreground": "#8FBCBB"
953
- }
954
- }, {
955
- "name": "[Markdown] Markup Italic",
956
- "scope": "text.html.markdown markup.italic",
957
- "settings": {
958
- "fontStyle": "italic"
959
- }
960
- }, {
961
- "name": "[Markdown] Markup Link",
962
- "scope": "text.html.markdown markup.underline.link",
963
- "settings": {
964
- "fontStyle": "underline"
965
- }
966
- }, {
967
- "name": "[Markdown] Markup List Numbered/Unnumbered",
968
- "scope": "text.html.markdown beginning.punctuation.definition.list",
969
- "settings": {
970
- "foreground": "#81A1C1"
971
- }
972
- }, {
973
- "name": "[Markdown] Markup Quote Punctuation Definition",
974
- "scope": "text.html.markdown beginning.punctuation.definition.quote",
975
- "settings": {
976
- "foreground": "#8FBCBB"
977
- }
978
- }, {
979
- "name": "[Markdown] Markup Quote Punctuation Definition",
980
- "scope": "text.html.markdown markup.quote",
981
- "settings": {
982
- "foreground": "#616E88"
983
- }
984
- }, {
985
- "name": "[Markdown] Markup Math Constant",
986
- "scope": "text.html.markdown constant.character.math.tex",
987
- "settings": {
988
- "foreground": "#81A1C1"
989
- }
990
- }, {
991
- "name": "[Markdown] Markup Math Definition Marker",
992
- "scope": ["text.html.markdown punctuation.definition.math.begin", "text.html.markdown punctuation.definition.math.end"],
993
- "settings": {
994
- "foreground": "#5E81AC"
995
- }
996
- }, {
997
- "name": "[Markdown] Markup Math Function Definition Marker",
998
- "scope": "text.html.markdown punctuation.definition.function.math.tex",
999
- "settings": {
1000
- "foreground": "#88C0D0"
1001
- }
1002
- }, {
1003
- "name": "[Markdown] Markup Math Operator",
1004
- "scope": "text.html.markdown punctuation.math.operator.latex",
1005
- "settings": {
1006
- "foreground": "#81A1C1"
1007
- }
1008
- }, {
1009
- "name": "[Markdown] Punctuation Definition Heading",
1010
- "scope": "text.html.markdown punctuation.definition.heading",
1011
- "settings": {
1012
- "foreground": "#81A1C1"
1013
- }
1014
- }, {
1015
- "name": "[Markdown] Punctuation Definition Constant/String",
1016
- "scope": ["text.html.markdown punctuation.definition.constant", "text.html.markdown punctuation.definition.string"],
1017
- "settings": {
1018
- "foreground": "#81A1C1"
1019
- }
1020
- }, {
1021
- "name": "[Markdown] String Other Link Description/Title",
1022
- "scope": ["text.html.markdown constant.other.reference.link", "text.html.markdown string.other.link.description", "text.html.markdown string.other.link.title"],
1023
- "settings": {
1024
- "foreground": "#88C0D0"
1025
- }
1026
- }, {
1027
- "name": "[Perl] Perl Sigils",
1028
- "scope": "source.perl punctuation.definition.variable",
1029
- "settings": {
1030
- "foreground": "#D8DEE9"
1031
- }
1032
- }, {
1033
- "name": "[PHP] Meta Function-Call Object",
1034
- "scope": ["source.php meta.function-call", "source.php meta.function-call.object"],
1035
- "settings": {
1036
- "foreground": "#88C0D0"
1037
- }
1038
- }, {
1039
- "name": "[Python] Decorator",
1040
- "scope": ["source.python entity.name.function.decorator", "source.python meta.function.decorator support.type"],
1041
- "settings": {
1042
- "foreground": "#D08770"
1043
- }
1044
- }, {
1045
- "name": "[Python] Function Call",
1046
- "scope": "source.python meta.function-call.generic",
1047
- "settings": {
1048
- "foreground": "#88C0D0"
1049
- }
1050
- }, {
1051
- "name": "[Python] Support Type",
1052
- "scope": "source.python support.type",
1053
- "settings": {
1054
- "foreground": "#88C0D0"
1055
- }
1056
- }, {
1057
- "name": "[Python] Function Parameter",
1058
- "scope": ["source.python variable.parameter.function.language"],
1059
- "settings": {
1060
- "foreground": "#D8DEE9"
1061
- }
1062
- }, {
1063
- "name": "[Python] Function Parameter Special",
1064
- "scope": ["source.python meta.function.parameters variable.parameter.function.language.special.self"],
1065
- "settings": {
1066
- "foreground": "#81A1C1"
1067
- }
1068
- }, {
1069
- "name": "[Rust] Entity types",
1070
- "scope": "source.rust entity.name.type",
1071
- "settings": {
1072
- "foreground": "#8FBCBB"
1073
- }
1074
- }, {
1075
- "name": "[Rust] Macro",
1076
- "scope": "source.rust meta.macro entity.name.function",
1077
- "settings": {
1078
- "fontStyle": "bold",
1079
- "foreground": "#88C0D0"
1080
- }
1081
- }, {
1082
- "name": "[Rust] Attributes",
1083
- "scope": ["source.rust meta.attribute", "source.rust meta.attribute punctuation", "source.rust meta.attribute keyword.operator"],
1084
- "settings": {
1085
- "foreground": "#5E81AC"
1086
- }
1087
- }, {
1088
- "name": "[Rust] Traits",
1089
- "scope": "source.rust entity.name.type.trait",
1090
- "settings": {
1091
- "fontStyle": "bold"
1092
- }
1093
- }, {
1094
- "name": "[Rust] Interpolation Bracket Curly",
1095
- "scope": "source.rust punctuation.definition.interpolation",
1096
- "settings": {
1097
- "foreground": "#EBCB8B"
1098
- }
1099
- }, {
1100
- "name": "[SCSS] Punctuation Definition Interpolation Bracket Curly",
1101
- "scope": ["source.css.scss punctuation.definition.interpolation.begin.bracket.curly", "source.css.scss punctuation.definition.interpolation.end.bracket.curly"],
1102
- "settings": {
1103
- "foreground": "#81A1C1"
1104
- }
1105
- }, {
1106
- "name": "[SCSS] Variable Interpolation",
1107
- "scope": "source.css.scss variable.interpolation",
1108
- "settings": {
1109
- "foreground": "#D8DEE9",
1110
- "fontStyle": "italic"
1111
- }
1112
- }, {
1113
- "name": "[TypeScript] Decorators",
1114
- "scope": ["source.ts punctuation.decorator", "source.ts meta.decorator variable.other.readwrite", "source.ts meta.decorator entity.name.function", "source.tsx punctuation.decorator", "source.tsx meta.decorator variable.other.readwrite", "source.tsx meta.decorator entity.name.function"],
1115
- "settings": {
1116
- "foreground": "#D08770"
1117
- }
1118
- }, {
1119
- "name": "[TypeScript] Object-literal keys",
1120
- "scope": ["source.ts meta.object-literal.key", "source.tsx meta.object-literal.key"],
1121
- "settings": {
1122
- "foreground": "#D8DEE9"
1123
- }
1124
- }, {
1125
- "name": "[TypeScript] Object-literal functions",
1126
- "scope": ["source.ts meta.object-literal.key entity.name.function", "source.tsx meta.object-literal.key entity.name.function"],
1127
- "settings": {
1128
- "foreground": "#88C0D0"
1129
- }
1130
- }, {
1131
- "name": "[TypeScript] Type/Class",
1132
- "scope": ["source.ts support.class", "source.ts support.type", "source.ts entity.name.type", "source.ts entity.name.class", "source.tsx support.class", "source.tsx support.type", "source.tsx entity.name.type", "source.tsx entity.name.class"],
1133
- "settings": {
1134
- "foreground": "#8FBCBB"
1135
- }
1136
- }, {
1137
- "name": "[TypeScript] Static Class Support",
1138
- "scope": ["source.ts support.constant.math", "source.ts support.constant.dom", "source.ts support.constant.json", "source.tsx support.constant.math", "source.tsx support.constant.dom", "source.tsx support.constant.json"],
1139
- "settings": {
1140
- "foreground": "#8FBCBB"
1141
- }
1142
- }, {
1143
- "name": "[TypeScript] Variables",
1144
- "scope": ["source.ts support.variable", "source.tsx support.variable"],
1145
- "settings": {
1146
- "foreground": "#D8DEE9"
1147
- }
1148
- }, {
1149
- "name": "[TypeScript] Parentheses in Template Strings",
1150
- "scope": ["source.ts meta.embedded.line meta.brace.square", "source.ts meta.embedded.line meta.brace.round", "source.tsx meta.embedded.line meta.brace.square", "source.tsx meta.embedded.line meta.brace.round"],
1151
- "settings": {
1152
- "foreground": "#ECEFF4"
1153
- }
1154
- }, {
1155
- "name": "[XML] Entity Name Tag Namespace",
1156
- "scope": "text.xml entity.name.tag.namespace",
1157
- "settings": {
1158
- "foreground": "#8FBCBB"
1159
- }
1160
- }, {
1161
- "name": "[XML] Keyword Other Doctype",
1162
- "scope": "text.xml keyword.other.doctype",
1163
- "settings": {
1164
- "foreground": "#5E81AC"
1165
- }
1166
- }, {
1167
- "name": "[XML] Meta Tag Preprocessor",
1168
- "scope": "text.xml meta.tag.preprocessor entity.name.tag",
1169
- "settings": {
1170
- "foreground": "#5E81AC"
1171
- }
1172
- }, {
1173
- "name": "[XML] Entity Name Tag Namespace",
1174
- "scope": ["text.xml string.unquoted.cdata", "text.xml string.unquoted.cdata punctuation.definition.string"],
1175
- "settings": {
1176
- "foreground": "#D08770",
1177
- "fontStyle": "italic"
1178
- }
1179
- }, {
1180
- "name": "[YAML] Entity Name Tag",
1181
- "scope": "source.yaml entity.name.tag",
1182
- "settings": {
1183
- "foreground": "#8FBCBB"
1184
- }
1185
- }]
1186
- },
1187
- "autoImport": true,
1188
- "showCopyButton": true,
1189
- "skipLanguages": [],
1190
- "filepath": "/Users/bytedance/github/targeral/modern-dev/website/module-tools/docs/zh/guide/advance/asset.mdx"
1191
- };
1192
- const frontmatter = {
1193
- "sidebar_position": 7
1194
- };
1195
- const toc = [{
1196
- "id": "默认行为",
1197
- "text": "默认行为",
1198
- "depth": 2
1199
- }, {
1200
- "id": "设置-cdn-前缀",
1201
- "text": "设置 CDN 前缀",
1202
- "depth": 2
1203
- }];
1204
- const title = `处理静态资源文件`;
1205
- const content = "\"---\\nsidebar_position: 7\\n---\\n\\n# 处理静态资源文件\\n\\n模块工程会对代码中使用的静态资源进行处理。如果需要配置,则可以使用 [`buildConfig.asset`](/api/config/build-config#asset) API。\\n\\n## 默认行为\\n\\n默认情况下,模块工程对于以下静态资源会进行处理:\\n\\n- `'.svg'`、`'.png'`、`'.jpg'`、`'.jpeg'`、`'.gif'`、`'.webp'`\\n- `'.ttf'`、`'.otf'`、`'.woff'`、`'.woff2'`、`'.eot'`\\n- `'.mp3'`、`'.mp4'`、`'.webm'`、`'.ogg'`、`'.wav'`、`'.flac'`、`'.aac'`、`'.mov'`\\n\\n对于静态文件的处理,模块工程目前支持的功能有:\\n\\n- 设置静态资源路径为 `./assets`。\\n- 对于超过 **10kb** 的文件会内联到代码中。\\n\\n让我们看下面的例子:\\n\\n<CH.Spotlight>\\n\\n```ts ./src/asset.ts\\nimport img from './bg.png';\\n//...\\n```\\n\\n---\\n\\n项目源代码。\\n\\n```ts ./src/asset.ts\\nimport img from './bg.png';\\n//...\\n```\\n\\n---\\n\\n如果 `bg.png` 的大小小于 10 kb,则此时产物目录结构和产物内容为。\\n\\n<CH.Code>\\n\\n```bash\\n./dist\\n└── asset.js\\n```\\n\\n---\\n\\n```js ./dist/asset.js\\nvar bg_default = 'data:image/png;base64,';\\nconsole.info(bg_default);\\n```\\n\\n</CH.Code>\\n\\n如果 `bg.png` 的大小大于 10 kb,则此时产物目录结构和产物内容为。\\n\\n<CH.Code>\\n\\n```bash\\n./dist\\n├── asset.js\\n└── assets\\n └── bg.13e2aba2.png\\n```\\n\\n---\\n\\n```js ./dist/asset.js\\nvar bg_default = 'assets/bg.13e2aba2.png';\\nconsole.info(bg_default);\\n```\\n\\n</CH.Code>\\n\\n</CH.Spotlight>\\n\\n当想要修改默认行为的时候,可以使用以下 API:\\n\\n- `asset.path`:修改静态资源文件输出路径。\\n- `asset.limit`:修改内联静态资源文件的阈值。\\n\\n## 设置 CDN 前缀\\n\\n如果项目运行的环境是在浏览器下,我们有可能需要静态资源托管至 CDN,然后在生产环境使用。\\n\\n那么此时默认生成的构建产物中,我们需要在静态资源文件的路径前面增加 CDN 的基础路径。还是看一个例子:\\n\\n<CH.Spotlight>\\n\\n```ts ./src/asset.ts\\nimport img from './bg.png';\\n//...\\n```\\n\\n---\\n\\n项目源代码。\\n\\n```ts ./src/asset.ts\\n\\n```\\n\\n---\\n\\n`modern.config` 配置为。\\n\\n```ts ./modern.config.ts\\nexport default defineConfig({\\n buildConfig: {\\n format: 'umd',\\n asset: {\\n publicPath: 'https://cdn/',\\n },\\n },\\n});\\n```\\n\\n---\\n\\n如果 `bg.png` 的大小大于 10 kb,则此时产物内容为。\\n\\n```js ./dist/asset.js focus=7:7\\n(function (global, factory) {\\n if (typeof module === 'object' && typeof module.exports === 'object')\\n factory();\\n else if (typeof define === 'function' && define.amd) define([], factory);\\n else if (\\n (global = typeof globalThis !== 'undefined' ? globalThis : global || self)\\n )\\n factory();\\n})(this, function () {\\n 'use strict';\\n var bg_default = 'http://cdn/assets/bg.13e2aba2.png';\\n // src/asset.tsx\\n console.info(bg_default);\\n});\\n```\\n\\n</CH.Spotlight>\\n\"";
1206
- function _createMdxContent(props) {
1207
- const _components = Object.assign({
1208
- h1: "h1",
1209
- a: "a",
1210
- p: "p",
1211
- code: "code",
1212
- h2: "h2",
1213
- ul: "ul",
1214
- li: "li",
1215
- strong: "strong",
1216
- hr: "hr"
1217
- }, props.components);
1218
- if (!CH) _missingMdxReference("CH", false, "24:1-80:16");
1219
- if (!CH.Code) _missingMdxReference("CH.Code", true, "62:1-78:11");
1220
- if (!CH.CodeSlot) _missingMdxReference("CH.CodeSlot", true);
1221
- if (!CH.Spotlight) _missingMdxReference("CH.Spotlight", true, "24:1-80:16");
1222
- return (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
1223
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.h1, {
1224
- id: "处理静态资源文件",
1225
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.a, {
1226
- className: "header-anchor",
1227
- "aria-hidden": "true",
1228
- href: "#处理静态资源文件",
1229
- children: "#"
1230
- }), "处理静态资源文件"]
1231
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.p, {
1232
- children: ["模块工程会对代码中使用的静态资源进行处理。如果需要配置,则可以使用 ", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.a, {
1233
- href: "/module-tools/api/config/build-config.html#asset-1",
1234
- children: (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1235
- children: "buildConfig.asset"
1236
- })
1237
- }), " API。"]
1238
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.h2, {
1239
- id: "默认行为",
1240
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.a, {
1241
- className: "header-anchor",
1242
- "aria-hidden": "true",
1243
- href: "#默认行为",
1244
- children: "#"
1245
- }), "默认行为"]
1246
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.p, {
1247
- children: "默认情况下,模块工程对于以下静态资源会进行处理:"
1248
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.ul, {
1249
- children: ["\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.li, {
1250
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1251
- children: "'.svg'"
1252
- }), "、", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1253
- children: "'.png'"
1254
- }), "、", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1255
- children: "'.jpg'"
1256
- }), "、", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1257
- children: "'.jpeg'"
1258
- }), "、", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1259
- children: "'.gif'"
1260
- }), "、", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1261
- children: "'.webp'"
1262
- })]
1263
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.li, {
1264
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1265
- children: "'.ttf'"
1266
- }), "、", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1267
- children: "'.otf'"
1268
- }), "、", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1269
- children: "'.woff'"
1270
- }), "、", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1271
- children: "'.woff2'"
1272
- }), "、", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1273
- children: "'.eot'"
1274
- })]
1275
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.li, {
1276
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1277
- children: "'.mp3'"
1278
- }), "、", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1279
- children: "'.mp4'"
1280
- }), "、", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1281
- children: "'.webm'"
1282
- }), "、", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1283
- children: "'.ogg'"
1284
- }), "、", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1285
- children: "'.wav'"
1286
- }), "、", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1287
- children: "'.flac'"
1288
- }), "、", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1289
- children: "'.aac'"
1290
- }), "、", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1291
- children: "'.mov'"
1292
- })]
1293
- }), "\n"]
1294
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.p, {
1295
- children: "对于静态文件的处理,模块工程目前支持的功能有:"
1296
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.ul, {
1297
- children: ["\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.li, {
1298
- children: ["设置静态资源路径为 ", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1299
- children: "./assets"
1300
- }), "。"]
1301
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.li, {
1302
- children: ["对于超过 ", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.strong, {
1303
- children: "10kb"
1304
- }), " 的文件会内联到代码中。"]
1305
- }), "\n"]
1306
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.p, {
1307
- children: "让我们看下面的例子:"
1308
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(CH.Spotlight, {
1309
- codeConfig: chCodeConfig,
1310
- editorSteps: [{
1311
- "northPanel": {
1312
- "tabs": ["./src/asset.ts"],
1313
- "active": "./src/asset.ts",
1314
- "heightRatio": 1
1315
- },
1316
- "files": [{
1317
- "name": "./src/asset.ts",
1318
- "focus": "",
1319
- "code": {
1320
- "lines": [{
1321
- "tokens": [{
1322
- "content": "import",
1323
- "props": {
1324
- "style": {
1325
- "color": "#81A1C1"
1326
- }
1327
- }
1328
- }, {
1329
- "content": " ",
1330
- "props": {
1331
- "style": {
1332
- "color": "#D8DEE9FF"
1333
- }
1334
- }
1335
- }, {
1336
- "content": "img",
1337
- "props": {
1338
- "style": {
1339
- "color": "#D8DEE9"
1340
- }
1341
- }
1342
- }, {
1343
- "content": " ",
1344
- "props": {
1345
- "style": {
1346
- "color": "#D8DEE9FF"
1347
- }
1348
- }
1349
- }, {
1350
- "content": "from",
1351
- "props": {
1352
- "style": {
1353
- "color": "#81A1C1"
1354
- }
1355
- }
1356
- }, {
1357
- "content": " ",
1358
- "props": {
1359
- "style": {
1360
- "color": "#D8DEE9FF"
1361
- }
1362
- }
1363
- }, {
1364
- "content": "'",
1365
- "props": {
1366
- "style": {
1367
- "color": "#ECEFF4"
1368
- }
1369
- }
1370
- }, {
1371
- "content": "./bg.png",
1372
- "props": {
1373
- "style": {
1374
- "color": "#A3BE8C"
1375
- }
1376
- }
1377
- }, {
1378
- "content": "'",
1379
- "props": {
1380
- "style": {
1381
- "color": "#ECEFF4"
1382
- }
1383
- }
1384
- }, {
1385
- "content": ";",
1386
- "props": {
1387
- "style": {
1388
- "color": "#81A1C1"
1389
- }
1390
- }
1391
- }]
1392
- }, {
1393
- "tokens": [{
1394
- "content": "//...",
1395
- "props": {
1396
- "style": {
1397
- "color": "#616E88"
1398
- }
1399
- }
1400
- }]
1401
- }],
1402
- "lang": "ts"
1403
- },
1404
- "annotations": []
1405
- }]
1406
- }, {
1407
- "northPanel": {
1408
- "tabs": ["./src/asset.ts"],
1409
- "active": "./src/asset.ts",
1410
- "heightRatio": 1
1411
- },
1412
- "files": [{
1413
- "name": "./src/asset.ts",
1414
- "focus": "",
1415
- "code": {
1416
- "lines": [{
1417
- "tokens": [{
1418
- "content": "import",
1419
- "props": {
1420
- "style": {
1421
- "color": "#81A1C1"
1422
- }
1423
- }
1424
- }, {
1425
- "content": " ",
1426
- "props": {
1427
- "style": {
1428
- "color": "#D8DEE9FF"
1429
- }
1430
- }
1431
- }, {
1432
- "content": "img",
1433
- "props": {
1434
- "style": {
1435
- "color": "#D8DEE9"
1436
- }
1437
- }
1438
- }, {
1439
- "content": " ",
1440
- "props": {
1441
- "style": {
1442
- "color": "#D8DEE9FF"
1443
- }
1444
- }
1445
- }, {
1446
- "content": "from",
1447
- "props": {
1448
- "style": {
1449
- "color": "#81A1C1"
1450
- }
1451
- }
1452
- }, {
1453
- "content": " ",
1454
- "props": {
1455
- "style": {
1456
- "color": "#D8DEE9FF"
1457
- }
1458
- }
1459
- }, {
1460
- "content": "'",
1461
- "props": {
1462
- "style": {
1463
- "color": "#ECEFF4"
1464
- }
1465
- }
1466
- }, {
1467
- "content": "./bg.png",
1468
- "props": {
1469
- "style": {
1470
- "color": "#A3BE8C"
1471
- }
1472
- }
1473
- }, {
1474
- "content": "'",
1475
- "props": {
1476
- "style": {
1477
- "color": "#ECEFF4"
1478
- }
1479
- }
1480
- }, {
1481
- "content": ";",
1482
- "props": {
1483
- "style": {
1484
- "color": "#81A1C1"
1485
- }
1486
- }
1487
- }]
1488
- }, {
1489
- "tokens": [{
1490
- "content": "//...",
1491
- "props": {
1492
- "style": {
1493
- "color": "#616E88"
1494
- }
1495
- }
1496
- }]
1497
- }],
1498
- "lang": "ts"
1499
- },
1500
- "annotations": []
1501
- }],
1502
- "southPanel": undefined
1503
- }, {
1504
- "northPanel": {
1505
- "tabs": ["./src/asset.ts", ""],
1506
- "active": "",
1507
- "heightRatio": 0.5
1508
- },
1509
- "files": [{
1510
- "name": "./src/asset.ts",
1511
- "focus": "",
1512
- "code": {
1513
- "lines": [{
1514
- "tokens": [{
1515
- "content": "import",
1516
- "props": {
1517
- "style": {
1518
- "color": "#81A1C1"
1519
- }
1520
- }
1521
- }, {
1522
- "content": " ",
1523
- "props": {
1524
- "style": {
1525
- "color": "#D8DEE9FF"
1526
- }
1527
- }
1528
- }, {
1529
- "content": "img",
1530
- "props": {
1531
- "style": {
1532
- "color": "#D8DEE9"
1533
- }
1534
- }
1535
- }, {
1536
- "content": " ",
1537
- "props": {
1538
- "style": {
1539
- "color": "#D8DEE9FF"
1540
- }
1541
- }
1542
- }, {
1543
- "content": "from",
1544
- "props": {
1545
- "style": {
1546
- "color": "#81A1C1"
1547
- }
1548
- }
1549
- }, {
1550
- "content": " ",
1551
- "props": {
1552
- "style": {
1553
- "color": "#D8DEE9FF"
1554
- }
1555
- }
1556
- }, {
1557
- "content": "'",
1558
- "props": {
1559
- "style": {
1560
- "color": "#ECEFF4"
1561
- }
1562
- }
1563
- }, {
1564
- "content": "./bg.png",
1565
- "props": {
1566
- "style": {
1567
- "color": "#A3BE8C"
1568
- }
1569
- }
1570
- }, {
1571
- "content": "'",
1572
- "props": {
1573
- "style": {
1574
- "color": "#ECEFF4"
1575
- }
1576
- }
1577
- }, {
1578
- "content": ";",
1579
- "props": {
1580
- "style": {
1581
- "color": "#81A1C1"
1582
- }
1583
- }
1584
- }]
1585
- }, {
1586
- "tokens": [{
1587
- "content": "//...",
1588
- "props": {
1589
- "style": {
1590
- "color": "#616E88"
1591
- }
1592
- }
1593
- }]
1594
- }],
1595
- "lang": "ts"
1596
- },
1597
- "annotations": []
1598
- }, {
1599
- "name": "",
1600
- "focus": "",
1601
- "code": {
1602
- "lines": [{
1603
- "tokens": [{
1604
- "content": "./dist",
1605
- "props": {
1606
- "style": {
1607
- "color": "#D8DEE9FF"
1608
- }
1609
- }
1610
- }]
1611
- }, {
1612
- "tokens": [{
1613
- "content": "└── asset.js",
1614
- "props": {
1615
- "style": {
1616
- "color": "#D8DEE9FF"
1617
- }
1618
- }
1619
- }]
1620
- }],
1621
- "lang": "bash"
1622
- },
1623
- "annotations": []
1624
- }, {
1625
- "name": "./dist/asset.js",
1626
- "focus": "",
1627
- "code": {
1628
- "lines": [{
1629
- "tokens": [{
1630
- "content": "var",
1631
- "props": {
1632
- "style": {
1633
- "color": "#81A1C1"
1634
- }
1635
- }
1636
- }, {
1637
- "content": " ",
1638
- "props": {
1639
- "style": {
1640
- "color": "#D8DEE9FF"
1641
- }
1642
- }
1643
- }, {
1644
- "content": "bg_default",
1645
- "props": {
1646
- "style": {
1647
- "color": "#D8DEE9"
1648
- }
1649
- }
1650
- }, {
1651
- "content": " ",
1652
- "props": {
1653
- "style": {
1654
- "color": "#D8DEE9FF"
1655
- }
1656
- }
1657
- }, {
1658
- "content": "=",
1659
- "props": {
1660
- "style": {
1661
- "color": "#81A1C1"
1662
- }
1663
- }
1664
- }, {
1665
- "content": " ",
1666
- "props": {
1667
- "style": {
1668
- "color": "#D8DEE9FF"
1669
- }
1670
- }
1671
- }, {
1672
- "content": "'",
1673
- "props": {
1674
- "style": {
1675
- "color": "#ECEFF4"
1676
- }
1677
- }
1678
- }, {
1679
- "content": "data:image/png;base64,",
1680
- "props": {
1681
- "style": {
1682
- "color": "#A3BE8C"
1683
- }
1684
- }
1685
- }, {
1686
- "content": "'",
1687
- "props": {
1688
- "style": {
1689
- "color": "#ECEFF4"
1690
- }
1691
- }
1692
- }, {
1693
- "content": ";",
1694
- "props": {
1695
- "style": {
1696
- "color": "#81A1C1"
1697
- }
1698
- }
1699
- }]
1700
- }, {
1701
- "tokens": [{
1702
- "content": "console",
1703
- "props": {
1704
- "style": {
1705
- "color": "#D8DEE9"
1706
- }
1707
- }
1708
- }, {
1709
- "content": ".",
1710
- "props": {
1711
- "style": {
1712
- "color": "#ECEFF4"
1713
- }
1714
- }
1715
- }, {
1716
- "content": "info",
1717
- "props": {
1718
- "style": {
1719
- "color": "#88C0D0"
1720
- }
1721
- }
1722
- }, {
1723
- "content": "(",
1724
- "props": {
1725
- "style": {
1726
- "color": "#D8DEE9FF"
1727
- }
1728
- }
1729
- }, {
1730
- "content": "bg_default",
1731
- "props": {
1732
- "style": {
1733
- "color": "#D8DEE9"
1734
- }
1735
- }
1736
- }, {
1737
- "content": ")",
1738
- "props": {
1739
- "style": {
1740
- "color": "#D8DEE9FF"
1741
- }
1742
- }
1743
- }, {
1744
- "content": ";",
1745
- "props": {
1746
- "style": {
1747
- "color": "#81A1C1"
1748
- }
1749
- }
1750
- }]
1751
- }],
1752
- "lang": "js"
1753
- },
1754
- "annotations": []
1755
- }],
1756
- "southPanel": {
1757
- "tabs": ["./dist/asset.js"],
1758
- "active": "./dist/asset.js",
1759
- "heightRatio": 0.5
1760
- }
1761
- }],
1762
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
1763
- children: (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(CH.CodeSlot, {})
1764
- }), (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
1765
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.p, {
1766
- children: "项目源代码。"
1767
- }), (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(CH.CodeSlot, {})]
1768
- }), (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
1769
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.p, {
1770
- children: ["如果 ", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1771
- children: "bg.png"
1772
- }), " 的大小小于 10 kb,则此时产物目录结构和产物内容为。"]
1773
- }), (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(CH.CodeSlot, {}), (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.p, {
1774
- children: ["如果 ", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
1775
- children: "bg.png"
1776
- }), " 的大小大于 10 kb,则此时产物目录结构和产物内容为。"]
1777
- }), (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(CH.Code, {
1778
- codeConfig: chCodeConfig,
1779
- northPanel: {
1780
- "tabs": [""],
1781
- "active": "",
1782
- "heightRatio": 0.6
1783
- },
1784
- southPanel: {
1785
- "tabs": ["./dist/asset.js"],
1786
- "active": "./dist/asset.js",
1787
- "heightRatio": 0.4
1788
- },
1789
- files: [{
1790
- "name": "",
1791
- "focus": "",
1792
- "code": {
1793
- "lines": [{
1794
- "tokens": [{
1795
- "content": "./dist",
1796
- "props": {
1797
- "style": {
1798
- "color": "#D8DEE9FF"
1799
- }
1800
- }
1801
- }]
1802
- }, {
1803
- "tokens": [{
1804
- "content": "├── asset.js",
1805
- "props": {
1806
- "style": {
1807
- "color": "#D8DEE9FF"
1808
- }
1809
- }
1810
- }]
1811
- }, {
1812
- "tokens": [{
1813
- "content": "└── assets",
1814
- "props": {
1815
- "style": {
1816
- "color": "#D8DEE9FF"
1817
- }
1818
- }
1819
- }]
1820
- }, {
1821
- "tokens": [{
1822
- "content": " └── bg.13e2aba2.png",
1823
- "props": {
1824
- "style": {
1825
- "color": "#D8DEE9FF"
1826
- }
1827
- }
1828
- }]
1829
- }],
1830
- "lang": "bash"
1831
- },
1832
- "annotations": []
1833
- }, {
1834
- "name": "./dist/asset.js",
1835
- "focus": "",
1836
- "code": {
1837
- "lines": [{
1838
- "tokens": [{
1839
- "content": "var",
1840
- "props": {
1841
- "style": {
1842
- "color": "#81A1C1"
1843
- }
1844
- }
1845
- }, {
1846
- "content": " ",
1847
- "props": {
1848
- "style": {
1849
- "color": "#D8DEE9FF"
1850
- }
1851
- }
1852
- }, {
1853
- "content": "bg_default",
1854
- "props": {
1855
- "style": {
1856
- "color": "#D8DEE9"
1857
- }
1858
- }
1859
- }, {
1860
- "content": " ",
1861
- "props": {
1862
- "style": {
1863
- "color": "#D8DEE9FF"
1864
- }
1865
- }
1866
- }, {
1867
- "content": "=",
1868
- "props": {
1869
- "style": {
1870
- "color": "#81A1C1"
1871
- }
1872
- }
1873
- }, {
1874
- "content": " ",
1875
- "props": {
1876
- "style": {
1877
- "color": "#D8DEE9FF"
1878
- }
1879
- }
1880
- }, {
1881
- "content": "'",
1882
- "props": {
1883
- "style": {
1884
- "color": "#ECEFF4"
1885
- }
1886
- }
1887
- }, {
1888
- "content": "assets/bg.13e2aba2.png",
1889
- "props": {
1890
- "style": {
1891
- "color": "#A3BE8C"
1892
- }
1893
- }
1894
- }, {
1895
- "content": "'",
1896
- "props": {
1897
- "style": {
1898
- "color": "#ECEFF4"
1899
- }
1900
- }
1901
- }, {
1902
- "content": ";",
1903
- "props": {
1904
- "style": {
1905
- "color": "#81A1C1"
1906
- }
1907
- }
1908
- }]
1909
- }, {
1910
- "tokens": [{
1911
- "content": "console",
1912
- "props": {
1913
- "style": {
1914
- "color": "#D8DEE9"
1915
- }
1916
- }
1917
- }, {
1918
- "content": ".",
1919
- "props": {
1920
- "style": {
1921
- "color": "#ECEFF4"
1922
- }
1923
- }
1924
- }, {
1925
- "content": "info",
1926
- "props": {
1927
- "style": {
1928
- "color": "#88C0D0"
1929
- }
1930
- }
1931
- }, {
1932
- "content": "(",
1933
- "props": {
1934
- "style": {
1935
- "color": "#D8DEE9FF"
1936
- }
1937
- }
1938
- }, {
1939
- "content": "bg_default",
1940
- "props": {
1941
- "style": {
1942
- "color": "#D8DEE9"
1943
- }
1944
- }
1945
- }, {
1946
- "content": ")",
1947
- "props": {
1948
- "style": {
1949
- "color": "#D8DEE9FF"
1950
- }
1951
- }
1952
- }, {
1953
- "content": ";",
1954
- "props": {
1955
- "style": {
1956
- "color": "#81A1C1"
1957
- }
1958
- }
1959
- }]
1960
- }],
1961
- "lang": "js"
1962
- },
1963
- "annotations": []
1964
- }],
1965
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(CH.Code, {
1966
- codeConfig: chCodeConfig,
1967
- northPanel: {
1968
- "tabs": [""],
1969
- "active": "",
1970
- "heightRatio": 1
1971
- },
1972
- files: [{
1973
- "name": "",
1974
- "focus": "",
1975
- "code": {
1976
- "lines": [{
1977
- "tokens": [{
1978
- "content": "./dist",
1979
- "props": {
1980
- "style": {
1981
- "color": "#D8DEE9FF"
1982
- }
1983
- }
1984
- }]
1985
- }, {
1986
- "tokens": [{
1987
- "content": "├── asset.js",
1988
- "props": {
1989
- "style": {
1990
- "color": "#D8DEE9FF"
1991
- }
1992
- }
1993
- }]
1994
- }, {
1995
- "tokens": [{
1996
- "content": "└── assets",
1997
- "props": {
1998
- "style": {
1999
- "color": "#D8DEE9FF"
2000
- }
2001
- }
2002
- }]
2003
- }, {
2004
- "tokens": [{
2005
- "content": " └── bg.13e2aba2.png",
2006
- "props": {
2007
- "style": {
2008
- "color": "#D8DEE9FF"
2009
- }
2010
- }
2011
- }]
2012
- }],
2013
- "lang": "bash"
2014
- },
2015
- "annotations": []
2016
- }]
2017
- }), (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.hr, {}), (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(CH.Code, {
2018
- codeConfig: chCodeConfig,
2019
- northPanel: {
2020
- "tabs": ["./dist/asset.js"],
2021
- "active": "./dist/asset.js",
2022
- "heightRatio": 1
2023
- },
2024
- files: [{
2025
- "name": "./dist/asset.js",
2026
- "focus": "",
2027
- "code": {
2028
- "lines": [{
2029
- "tokens": [{
2030
- "content": "var",
2031
- "props": {
2032
- "style": {
2033
- "color": "#81A1C1"
2034
- }
2035
- }
2036
- }, {
2037
- "content": " ",
2038
- "props": {
2039
- "style": {
2040
- "color": "#D8DEE9FF"
2041
- }
2042
- }
2043
- }, {
2044
- "content": "bg_default",
2045
- "props": {
2046
- "style": {
2047
- "color": "#D8DEE9"
2048
- }
2049
- }
2050
- }, {
2051
- "content": " ",
2052
- "props": {
2053
- "style": {
2054
- "color": "#D8DEE9FF"
2055
- }
2056
- }
2057
- }, {
2058
- "content": "=",
2059
- "props": {
2060
- "style": {
2061
- "color": "#81A1C1"
2062
- }
2063
- }
2064
- }, {
2065
- "content": " ",
2066
- "props": {
2067
- "style": {
2068
- "color": "#D8DEE9FF"
2069
- }
2070
- }
2071
- }, {
2072
- "content": "'",
2073
- "props": {
2074
- "style": {
2075
- "color": "#ECEFF4"
2076
- }
2077
- }
2078
- }, {
2079
- "content": "assets/bg.13e2aba2.png",
2080
- "props": {
2081
- "style": {
2082
- "color": "#A3BE8C"
2083
- }
2084
- }
2085
- }, {
2086
- "content": "'",
2087
- "props": {
2088
- "style": {
2089
- "color": "#ECEFF4"
2090
- }
2091
- }
2092
- }, {
2093
- "content": ";",
2094
- "props": {
2095
- "style": {
2096
- "color": "#81A1C1"
2097
- }
2098
- }
2099
- }]
2100
- }, {
2101
- "tokens": [{
2102
- "content": "console",
2103
- "props": {
2104
- "style": {
2105
- "color": "#D8DEE9"
2106
- }
2107
- }
2108
- }, {
2109
- "content": ".",
2110
- "props": {
2111
- "style": {
2112
- "color": "#ECEFF4"
2113
- }
2114
- }
2115
- }, {
2116
- "content": "info",
2117
- "props": {
2118
- "style": {
2119
- "color": "#88C0D0"
2120
- }
2121
- }
2122
- }, {
2123
- "content": "(",
2124
- "props": {
2125
- "style": {
2126
- "color": "#D8DEE9FF"
2127
- }
2128
- }
2129
- }, {
2130
- "content": "bg_default",
2131
- "props": {
2132
- "style": {
2133
- "color": "#D8DEE9"
2134
- }
2135
- }
2136
- }, {
2137
- "content": ")",
2138
- "props": {
2139
- "style": {
2140
- "color": "#D8DEE9FF"
2141
- }
2142
- }
2143
- }, {
2144
- "content": ";",
2145
- "props": {
2146
- "style": {
2147
- "color": "#81A1C1"
2148
- }
2149
- }
2150
- }]
2151
- }],
2152
- "lang": "js"
2153
- },
2154
- "annotations": []
2155
- }]
2156
- })]
2157
- })]
2158
- })]
2159
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.p, {
2160
- children: "当想要修改默认行为的时候,可以使用以下 API:"
2161
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.ul, {
2162
- children: ["\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.li, {
2163
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
2164
- children: "asset.path"
2165
- }), ":修改静态资源文件输出路径。"]
2166
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.li, {
2167
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
2168
- children: "asset.limit"
2169
- }), ":修改内联静态资源文件的阈值。"]
2170
- }), "\n"]
2171
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.h2, {
2172
- id: "设置-cdn-前缀",
2173
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.a, {
2174
- className: "header-anchor",
2175
- "aria-hidden": "true",
2176
- href: "#设置-cdn-前缀",
2177
- children: "#"
2178
- }), "设置 CDN 前缀"]
2179
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.p, {
2180
- children: "如果项目运行的环境是在浏览器下,我们有可能需要静态资源托管至 CDN,然后在生产环境使用。"
2181
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.p, {
2182
- children: "那么此时默认生成的构建产物中,我们需要在静态资源文件的路径前面增加 CDN 的基础路径。还是看一个例子:"
2183
- }), "\n", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(CH.Spotlight, {
2184
- codeConfig: chCodeConfig,
2185
- editorSteps: [{
2186
- "northPanel": {
2187
- "tabs": ["./src/asset.ts"],
2188
- "active": "./src/asset.ts",
2189
- "heightRatio": 1
2190
- },
2191
- "files": [{
2192
- "name": "./src/asset.ts",
2193
- "focus": "",
2194
- "code": {
2195
- "lines": [{
2196
- "tokens": [{
2197
- "content": "import",
2198
- "props": {
2199
- "style": {
2200
- "color": "#81A1C1"
2201
- }
2202
- }
2203
- }, {
2204
- "content": " ",
2205
- "props": {
2206
- "style": {
2207
- "color": "#D8DEE9FF"
2208
- }
2209
- }
2210
- }, {
2211
- "content": "img",
2212
- "props": {
2213
- "style": {
2214
- "color": "#D8DEE9"
2215
- }
2216
- }
2217
- }, {
2218
- "content": " ",
2219
- "props": {
2220
- "style": {
2221
- "color": "#D8DEE9FF"
2222
- }
2223
- }
2224
- }, {
2225
- "content": "from",
2226
- "props": {
2227
- "style": {
2228
- "color": "#81A1C1"
2229
- }
2230
- }
2231
- }, {
2232
- "content": " ",
2233
- "props": {
2234
- "style": {
2235
- "color": "#D8DEE9FF"
2236
- }
2237
- }
2238
- }, {
2239
- "content": "'",
2240
- "props": {
2241
- "style": {
2242
- "color": "#ECEFF4"
2243
- }
2244
- }
2245
- }, {
2246
- "content": "./bg.png",
2247
- "props": {
2248
- "style": {
2249
- "color": "#A3BE8C"
2250
- }
2251
- }
2252
- }, {
2253
- "content": "'",
2254
- "props": {
2255
- "style": {
2256
- "color": "#ECEFF4"
2257
- }
2258
- }
2259
- }, {
2260
- "content": ";",
2261
- "props": {
2262
- "style": {
2263
- "color": "#81A1C1"
2264
- }
2265
- }
2266
- }]
2267
- }, {
2268
- "tokens": [{
2269
- "content": "//...",
2270
- "props": {
2271
- "style": {
2272
- "color": "#616E88"
2273
- }
2274
- }
2275
- }]
2276
- }],
2277
- "lang": "ts"
2278
- },
2279
- "annotations": []
2280
- }]
2281
- }, {
2282
- "northPanel": {
2283
- "tabs": ["./src/asset.ts"],
2284
- "active": "./src/asset.ts",
2285
- "heightRatio": 1
2286
- },
2287
- "files": [{
2288
- "name": "./src/asset.ts",
2289
- "focus": "",
2290
- "code": {
2291
- "lines": [{
2292
- "tokens": [{
2293
- "content": "import",
2294
- "props": {
2295
- "style": {
2296
- "color": "#81A1C1"
2297
- }
2298
- }
2299
- }, {
2300
- "content": " ",
2301
- "props": {
2302
- "style": {
2303
- "color": "#D8DEE9FF"
2304
- }
2305
- }
2306
- }, {
2307
- "content": "img",
2308
- "props": {
2309
- "style": {
2310
- "color": "#D8DEE9"
2311
- }
2312
- }
2313
- }, {
2314
- "content": " ",
2315
- "props": {
2316
- "style": {
2317
- "color": "#D8DEE9FF"
2318
- }
2319
- }
2320
- }, {
2321
- "content": "from",
2322
- "props": {
2323
- "style": {
2324
- "color": "#81A1C1"
2325
- }
2326
- }
2327
- }, {
2328
- "content": " ",
2329
- "props": {
2330
- "style": {
2331
- "color": "#D8DEE9FF"
2332
- }
2333
- }
2334
- }, {
2335
- "content": "'",
2336
- "props": {
2337
- "style": {
2338
- "color": "#ECEFF4"
2339
- }
2340
- }
2341
- }, {
2342
- "content": "./bg.png",
2343
- "props": {
2344
- "style": {
2345
- "color": "#A3BE8C"
2346
- }
2347
- }
2348
- }, {
2349
- "content": "'",
2350
- "props": {
2351
- "style": {
2352
- "color": "#ECEFF4"
2353
- }
2354
- }
2355
- }, {
2356
- "content": ";",
2357
- "props": {
2358
- "style": {
2359
- "color": "#81A1C1"
2360
- }
2361
- }
2362
- }]
2363
- }, {
2364
- "tokens": [{
2365
- "content": "//...",
2366
- "props": {
2367
- "style": {
2368
- "color": "#616E88"
2369
- }
2370
- }
2371
- }]
2372
- }],
2373
- "lang": "ts"
2374
- },
2375
- "annotations": []
2376
- }],
2377
- "southPanel": undefined
2378
- }, {
2379
- "northPanel": {
2380
- "tabs": ["./src/asset.ts", "./modern.config.ts"],
2381
- "active": "./modern.config.ts",
2382
- "heightRatio": 1
2383
- },
2384
- "files": [{
2385
- "name": "./src/asset.ts",
2386
- "focus": "",
2387
- "code": {
2388
- "lines": [{
2389
- "tokens": [{
2390
- "content": "import",
2391
- "props": {
2392
- "style": {
2393
- "color": "#81A1C1"
2394
- }
2395
- }
2396
- }, {
2397
- "content": " ",
2398
- "props": {
2399
- "style": {
2400
- "color": "#D8DEE9FF"
2401
- }
2402
- }
2403
- }, {
2404
- "content": "img",
2405
- "props": {
2406
- "style": {
2407
- "color": "#D8DEE9"
2408
- }
2409
- }
2410
- }, {
2411
- "content": " ",
2412
- "props": {
2413
- "style": {
2414
- "color": "#D8DEE9FF"
2415
- }
2416
- }
2417
- }, {
2418
- "content": "from",
2419
- "props": {
2420
- "style": {
2421
- "color": "#81A1C1"
2422
- }
2423
- }
2424
- }, {
2425
- "content": " ",
2426
- "props": {
2427
- "style": {
2428
- "color": "#D8DEE9FF"
2429
- }
2430
- }
2431
- }, {
2432
- "content": "'",
2433
- "props": {
2434
- "style": {
2435
- "color": "#ECEFF4"
2436
- }
2437
- }
2438
- }, {
2439
- "content": "./bg.png",
2440
- "props": {
2441
- "style": {
2442
- "color": "#A3BE8C"
2443
- }
2444
- }
2445
- }, {
2446
- "content": "'",
2447
- "props": {
2448
- "style": {
2449
- "color": "#ECEFF4"
2450
- }
2451
- }
2452
- }, {
2453
- "content": ";",
2454
- "props": {
2455
- "style": {
2456
- "color": "#81A1C1"
2457
- }
2458
- }
2459
- }]
2460
- }, {
2461
- "tokens": [{
2462
- "content": "//...",
2463
- "props": {
2464
- "style": {
2465
- "color": "#616E88"
2466
- }
2467
- }
2468
- }]
2469
- }],
2470
- "lang": "ts"
2471
- },
2472
- "annotations": []
2473
- }, {
2474
- "name": "./modern.config.ts",
2475
- "focus": "",
2476
- "code": {
2477
- "lines": [{
2478
- "tokens": [{
2479
- "content": "export",
2480
- "props": {
2481
- "style": {
2482
- "color": "#81A1C1"
2483
- }
2484
- }
2485
- }, {
2486
- "content": " ",
2487
- "props": {
2488
- "style": {
2489
- "color": "#D8DEE9FF"
2490
- }
2491
- }
2492
- }, {
2493
- "content": "default",
2494
- "props": {
2495
- "style": {
2496
- "color": "#81A1C1"
2497
- }
2498
- }
2499
- }, {
2500
- "content": " ",
2501
- "props": {
2502
- "style": {
2503
- "color": "#D8DEE9FF"
2504
- }
2505
- }
2506
- }, {
2507
- "content": "defineConfig",
2508
- "props": {
2509
- "style": {
2510
- "color": "#88C0D0"
2511
- }
2512
- }
2513
- }, {
2514
- "content": "(",
2515
- "props": {
2516
- "style": {
2517
- "color": "#D8DEE9FF"
2518
- }
2519
- }
2520
- }, {
2521
- "content": "{",
2522
- "props": {
2523
- "style": {
2524
- "color": "#ECEFF4"
2525
- }
2526
- }
2527
- }]
2528
- }, {
2529
- "tokens": [{
2530
- "content": " ",
2531
- "props": {
2532
- "style": {
2533
- "color": "#D8DEE9FF"
2534
- }
2535
- }
2536
- }, {
2537
- "content": "buildConfig",
2538
- "props": {
2539
- "style": {
2540
- "color": "#D8DEE9"
2541
- }
2542
- }
2543
- }, {
2544
- "content": ":",
2545
- "props": {
2546
- "style": {
2547
- "color": "#ECEFF4"
2548
- }
2549
- }
2550
- }, {
2551
- "content": " ",
2552
- "props": {
2553
- "style": {
2554
- "color": "#D8DEE9FF"
2555
- }
2556
- }
2557
- }, {
2558
- "content": "{",
2559
- "props": {
2560
- "style": {
2561
- "color": "#ECEFF4"
2562
- }
2563
- }
2564
- }]
2565
- }, {
2566
- "tokens": [{
2567
- "content": " ",
2568
- "props": {
2569
- "style": {
2570
- "color": "#D8DEE9FF"
2571
- }
2572
- }
2573
- }, {
2574
- "content": "format",
2575
- "props": {
2576
- "style": {
2577
- "color": "#D8DEE9"
2578
- }
2579
- }
2580
- }, {
2581
- "content": ":",
2582
- "props": {
2583
- "style": {
2584
- "color": "#ECEFF4"
2585
- }
2586
- }
2587
- }, {
2588
- "content": " ",
2589
- "props": {
2590
- "style": {
2591
- "color": "#D8DEE9FF"
2592
- }
2593
- }
2594
- }, {
2595
- "content": "'",
2596
- "props": {
2597
- "style": {
2598
- "color": "#ECEFF4"
2599
- }
2600
- }
2601
- }, {
2602
- "content": "umd",
2603
- "props": {
2604
- "style": {
2605
- "color": "#A3BE8C"
2606
- }
2607
- }
2608
- }, {
2609
- "content": "'",
2610
- "props": {
2611
- "style": {
2612
- "color": "#ECEFF4"
2613
- }
2614
- }
2615
- }, {
2616
- "content": ",",
2617
- "props": {
2618
- "style": {
2619
- "color": "#ECEFF4"
2620
- }
2621
- }
2622
- }]
2623
- }, {
2624
- "tokens": [{
2625
- "content": " ",
2626
- "props": {
2627
- "style": {
2628
- "color": "#D8DEE9FF"
2629
- }
2630
- }
2631
- }, {
2632
- "content": "asset",
2633
- "props": {
2634
- "style": {
2635
- "color": "#D8DEE9"
2636
- }
2637
- }
2638
- }, {
2639
- "content": ":",
2640
- "props": {
2641
- "style": {
2642
- "color": "#ECEFF4"
2643
- }
2644
- }
2645
- }, {
2646
- "content": " ",
2647
- "props": {
2648
- "style": {
2649
- "color": "#D8DEE9FF"
2650
- }
2651
- }
2652
- }, {
2653
- "content": "{",
2654
- "props": {
2655
- "style": {
2656
- "color": "#ECEFF4"
2657
- }
2658
- }
2659
- }]
2660
- }, {
2661
- "tokens": [{
2662
- "content": " ",
2663
- "props": {
2664
- "style": {
2665
- "color": "#D8DEE9FF"
2666
- }
2667
- }
2668
- }, {
2669
- "content": "publicPath",
2670
- "props": {
2671
- "style": {
2672
- "color": "#D8DEE9"
2673
- }
2674
- }
2675
- }, {
2676
- "content": ":",
2677
- "props": {
2678
- "style": {
2679
- "color": "#ECEFF4"
2680
- }
2681
- }
2682
- }, {
2683
- "content": " ",
2684
- "props": {
2685
- "style": {
2686
- "color": "#D8DEE9FF"
2687
- }
2688
- }
2689
- }, {
2690
- "content": "'",
2691
- "props": {
2692
- "style": {
2693
- "color": "#ECEFF4"
2694
- }
2695
- }
2696
- }, {
2697
- "content": "https://cdn/",
2698
- "props": {
2699
- "style": {
2700
- "color": "#A3BE8C"
2701
- }
2702
- }
2703
- }, {
2704
- "content": "'",
2705
- "props": {
2706
- "style": {
2707
- "color": "#ECEFF4"
2708
- }
2709
- }
2710
- }, {
2711
- "content": ",",
2712
- "props": {
2713
- "style": {
2714
- "color": "#ECEFF4"
2715
- }
2716
- }
2717
- }]
2718
- }, {
2719
- "tokens": [{
2720
- "content": " ",
2721
- "props": {
2722
- "style": {
2723
- "color": "#D8DEE9FF"
2724
- }
2725
- }
2726
- }, {
2727
- "content": "},",
2728
- "props": {
2729
- "style": {
2730
- "color": "#ECEFF4"
2731
- }
2732
- }
2733
- }]
2734
- }, {
2735
- "tokens": [{
2736
- "content": " ",
2737
- "props": {
2738
- "style": {
2739
- "color": "#D8DEE9FF"
2740
- }
2741
- }
2742
- }, {
2743
- "content": "},",
2744
- "props": {
2745
- "style": {
2746
- "color": "#ECEFF4"
2747
- }
2748
- }
2749
- }]
2750
- }, {
2751
- "tokens": [{
2752
- "content": "}",
2753
- "props": {
2754
- "style": {
2755
- "color": "#ECEFF4"
2756
- }
2757
- }
2758
- }, {
2759
- "content": ")",
2760
- "props": {
2761
- "style": {
2762
- "color": "#D8DEE9FF"
2763
- }
2764
- }
2765
- }, {
2766
- "content": ";",
2767
- "props": {
2768
- "style": {
2769
- "color": "#81A1C1"
2770
- }
2771
- }
2772
- }]
2773
- }],
2774
- "lang": "ts"
2775
- },
2776
- "annotations": []
2777
- }],
2778
- "southPanel": undefined
2779
- }, {
2780
- "northPanel": {
2781
- "tabs": ["./src/asset.ts", "./dist/asset.js"],
2782
- "active": "./dist/asset.js",
2783
- "heightRatio": 1
2784
- },
2785
- "files": [{
2786
- "name": "./src/asset.ts",
2787
- "focus": "",
2788
- "code": {
2789
- "lines": [{
2790
- "tokens": [{
2791
- "content": "import",
2792
- "props": {
2793
- "style": {
2794
- "color": "#81A1C1"
2795
- }
2796
- }
2797
- }, {
2798
- "content": " ",
2799
- "props": {
2800
- "style": {
2801
- "color": "#D8DEE9FF"
2802
- }
2803
- }
2804
- }, {
2805
- "content": "img",
2806
- "props": {
2807
- "style": {
2808
- "color": "#D8DEE9"
2809
- }
2810
- }
2811
- }, {
2812
- "content": " ",
2813
- "props": {
2814
- "style": {
2815
- "color": "#D8DEE9FF"
2816
- }
2817
- }
2818
- }, {
2819
- "content": "from",
2820
- "props": {
2821
- "style": {
2822
- "color": "#81A1C1"
2823
- }
2824
- }
2825
- }, {
2826
- "content": " ",
2827
- "props": {
2828
- "style": {
2829
- "color": "#D8DEE9FF"
2830
- }
2831
- }
2832
- }, {
2833
- "content": "'",
2834
- "props": {
2835
- "style": {
2836
- "color": "#ECEFF4"
2837
- }
2838
- }
2839
- }, {
2840
- "content": "./bg.png",
2841
- "props": {
2842
- "style": {
2843
- "color": "#A3BE8C"
2844
- }
2845
- }
2846
- }, {
2847
- "content": "'",
2848
- "props": {
2849
- "style": {
2850
- "color": "#ECEFF4"
2851
- }
2852
- }
2853
- }, {
2854
- "content": ";",
2855
- "props": {
2856
- "style": {
2857
- "color": "#81A1C1"
2858
- }
2859
- }
2860
- }]
2861
- }, {
2862
- "tokens": [{
2863
- "content": "//...",
2864
- "props": {
2865
- "style": {
2866
- "color": "#616E88"
2867
- }
2868
- }
2869
- }]
2870
- }],
2871
- "lang": "ts"
2872
- },
2873
- "annotations": []
2874
- }, {
2875
- "name": "./dist/asset.js",
2876
- "focus": "7:7",
2877
- "code": {
2878
- "lines": [{
2879
- "tokens": [{
2880
- "content": "(",
2881
- "props": {
2882
- "style": {
2883
- "color": "#D8DEE9FF"
2884
- }
2885
- }
2886
- }, {
2887
- "content": "function",
2888
- "props": {
2889
- "style": {
2890
- "color": "#81A1C1"
2891
- }
2892
- }
2893
- }, {
2894
- "content": " ",
2895
- "props": {
2896
- "style": {
2897
- "color": "#D8DEE9FF"
2898
- }
2899
- }
2900
- }, {
2901
- "content": "(",
2902
- "props": {
2903
- "style": {
2904
- "color": "#ECEFF4"
2905
- }
2906
- }
2907
- }, {
2908
- "content": "global",
2909
- "props": {
2910
- "style": {
2911
- "color": "#D8DEE9"
2912
- }
2913
- }
2914
- }, {
2915
- "content": ",",
2916
- "props": {
2917
- "style": {
2918
- "color": "#ECEFF4"
2919
- }
2920
- }
2921
- }, {
2922
- "content": " ",
2923
- "props": {
2924
- "style": {
2925
- "color": "#D8DEE9FF"
2926
- }
2927
- }
2928
- }, {
2929
- "content": "factory",
2930
- "props": {
2931
- "style": {
2932
- "color": "#D8DEE9"
2933
- }
2934
- }
2935
- }, {
2936
- "content": ")",
2937
- "props": {
2938
- "style": {
2939
- "color": "#ECEFF4"
2940
- }
2941
- }
2942
- }, {
2943
- "content": " ",
2944
- "props": {
2945
- "style": {
2946
- "color": "#D8DEE9FF"
2947
- }
2948
- }
2949
- }, {
2950
- "content": "{",
2951
- "props": {
2952
- "style": {
2953
- "color": "#ECEFF4"
2954
- }
2955
- }
2956
- }]
2957
- }, {
2958
- "tokens": [{
2959
- "content": " ",
2960
- "props": {
2961
- "style": {
2962
- "color": "#D8DEE9FF"
2963
- }
2964
- }
2965
- }, {
2966
- "content": "if",
2967
- "props": {
2968
- "style": {
2969
- "color": "#81A1C1"
2970
- }
2971
- }
2972
- }, {
2973
- "content": " (",
2974
- "props": {
2975
- "style": {
2976
- "color": "#D8DEE9FF"
2977
- }
2978
- }
2979
- }, {
2980
- "content": "typeof",
2981
- "props": {
2982
- "style": {
2983
- "color": "#81A1C1"
2984
- }
2985
- }
2986
- }, {
2987
- "content": " ",
2988
- "props": {
2989
- "style": {
2990
- "color": "#D8DEE9FF"
2991
- }
2992
- }
2993
- }, {
2994
- "content": "module",
2995
- "props": {
2996
- "style": {
2997
- "color": "#8FBCBB"
2998
- }
2999
- }
3000
- }, {
3001
- "content": " ",
3002
- "props": {
3003
- "style": {
3004
- "color": "#D8DEE9FF"
3005
- }
3006
- }
3007
- }, {
3008
- "content": "===",
3009
- "props": {
3010
- "style": {
3011
- "color": "#81A1C1"
3012
- }
3013
- }
3014
- }, {
3015
- "content": " ",
3016
- "props": {
3017
- "style": {
3018
- "color": "#D8DEE9FF"
3019
- }
3020
- }
3021
- }, {
3022
- "content": "'",
3023
- "props": {
3024
- "style": {
3025
- "color": "#ECEFF4"
3026
- }
3027
- }
3028
- }, {
3029
- "content": "object",
3030
- "props": {
3031
- "style": {
3032
- "color": "#A3BE8C"
3033
- }
3034
- }
3035
- }, {
3036
- "content": "'",
3037
- "props": {
3038
- "style": {
3039
- "color": "#ECEFF4"
3040
- }
3041
- }
3042
- }, {
3043
- "content": " ",
3044
- "props": {
3045
- "style": {
3046
- "color": "#D8DEE9FF"
3047
- }
3048
- }
3049
- }, {
3050
- "content": "&&",
3051
- "props": {
3052
- "style": {
3053
- "color": "#81A1C1"
3054
- }
3055
- }
3056
- }, {
3057
- "content": " ",
3058
- "props": {
3059
- "style": {
3060
- "color": "#D8DEE9FF"
3061
- }
3062
- }
3063
- }, {
3064
- "content": "typeof",
3065
- "props": {
3066
- "style": {
3067
- "color": "#81A1C1"
3068
- }
3069
- }
3070
- }, {
3071
- "content": " ",
3072
- "props": {
3073
- "style": {
3074
- "color": "#D8DEE9FF"
3075
- }
3076
- }
3077
- }, {
3078
- "content": "module",
3079
- "props": {
3080
- "style": {
3081
- "color": "#8FBCBB"
3082
- }
3083
- }
3084
- }, {
3085
- "content": ".",
3086
- "props": {
3087
- "style": {
3088
- "color": "#ECEFF4"
3089
- }
3090
- }
3091
- }, {
3092
- "content": "exports",
3093
- "props": {
3094
- "style": {
3095
- "color": "#8FBCBB"
3096
- }
3097
- }
3098
- }, {
3099
- "content": " ",
3100
- "props": {
3101
- "style": {
3102
- "color": "#D8DEE9FF"
3103
- }
3104
- }
3105
- }, {
3106
- "content": "===",
3107
- "props": {
3108
- "style": {
3109
- "color": "#81A1C1"
3110
- }
3111
- }
3112
- }, {
3113
- "content": " ",
3114
- "props": {
3115
- "style": {
3116
- "color": "#D8DEE9FF"
3117
- }
3118
- }
3119
- }, {
3120
- "content": "'",
3121
- "props": {
3122
- "style": {
3123
- "color": "#ECEFF4"
3124
- }
3125
- }
3126
- }, {
3127
- "content": "object",
3128
- "props": {
3129
- "style": {
3130
- "color": "#A3BE8C"
3131
- }
3132
- }
3133
- }, {
3134
- "content": "'",
3135
- "props": {
3136
- "style": {
3137
- "color": "#ECEFF4"
3138
- }
3139
- }
3140
- }, {
3141
- "content": ")",
3142
- "props": {
3143
- "style": {
3144
- "color": "#D8DEE9FF"
3145
- }
3146
- }
3147
- }]
3148
- }, {
3149
- "tokens": [{
3150
- "content": " ",
3151
- "props": {
3152
- "style": {
3153
- "color": "#D8DEE9FF"
3154
- }
3155
- }
3156
- }, {
3157
- "content": "factory",
3158
- "props": {
3159
- "style": {
3160
- "color": "#88C0D0"
3161
- }
3162
- }
3163
- }, {
3164
- "content": "()",
3165
- "props": {
3166
- "style": {
3167
- "color": "#D8DEE9FF"
3168
- }
3169
- }
3170
- }, {
3171
- "content": ";",
3172
- "props": {
3173
- "style": {
3174
- "color": "#81A1C1"
3175
- }
3176
- }
3177
- }]
3178
- }, {
3179
- "tokens": [{
3180
- "content": " ",
3181
- "props": {
3182
- "style": {
3183
- "color": "#D8DEE9FF"
3184
- }
3185
- }
3186
- }, {
3187
- "content": "else",
3188
- "props": {
3189
- "style": {
3190
- "color": "#81A1C1"
3191
- }
3192
- }
3193
- }, {
3194
- "content": " ",
3195
- "props": {
3196
- "style": {
3197
- "color": "#D8DEE9FF"
3198
- }
3199
- }
3200
- }, {
3201
- "content": "if",
3202
- "props": {
3203
- "style": {
3204
- "color": "#81A1C1"
3205
- }
3206
- }
3207
- }, {
3208
- "content": " (",
3209
- "props": {
3210
- "style": {
3211
- "color": "#D8DEE9FF"
3212
- }
3213
- }
3214
- }, {
3215
- "content": "typeof",
3216
- "props": {
3217
- "style": {
3218
- "color": "#81A1C1"
3219
- }
3220
- }
3221
- }, {
3222
- "content": " ",
3223
- "props": {
3224
- "style": {
3225
- "color": "#D8DEE9FF"
3226
- }
3227
- }
3228
- }, {
3229
- "content": "define",
3230
- "props": {
3231
- "style": {
3232
- "color": "#D8DEE9"
3233
- }
3234
- }
3235
- }, {
3236
- "content": " ",
3237
- "props": {
3238
- "style": {
3239
- "color": "#D8DEE9FF"
3240
- }
3241
- }
3242
- }, {
3243
- "content": "===",
3244
- "props": {
3245
- "style": {
3246
- "color": "#81A1C1"
3247
- }
3248
- }
3249
- }, {
3250
- "content": " ",
3251
- "props": {
3252
- "style": {
3253
- "color": "#D8DEE9FF"
3254
- }
3255
- }
3256
- }, {
3257
- "content": "'",
3258
- "props": {
3259
- "style": {
3260
- "color": "#ECEFF4"
3261
- }
3262
- }
3263
- }, {
3264
- "content": "function",
3265
- "props": {
3266
- "style": {
3267
- "color": "#A3BE8C"
3268
- }
3269
- }
3270
- }, {
3271
- "content": "'",
3272
- "props": {
3273
- "style": {
3274
- "color": "#ECEFF4"
3275
- }
3276
- }
3277
- }, {
3278
- "content": " ",
3279
- "props": {
3280
- "style": {
3281
- "color": "#D8DEE9FF"
3282
- }
3283
- }
3284
- }, {
3285
- "content": "&&",
3286
- "props": {
3287
- "style": {
3288
- "color": "#81A1C1"
3289
- }
3290
- }
3291
- }, {
3292
- "content": " ",
3293
- "props": {
3294
- "style": {
3295
- "color": "#D8DEE9FF"
3296
- }
3297
- }
3298
- }, {
3299
- "content": "define",
3300
- "props": {
3301
- "style": {
3302
- "color": "#D8DEE9"
3303
- }
3304
- }
3305
- }, {
3306
- "content": ".",
3307
- "props": {
3308
- "style": {
3309
- "color": "#ECEFF4"
3310
- }
3311
- }
3312
- }, {
3313
- "content": "amd",
3314
- "props": {
3315
- "style": {
3316
- "color": "#D8DEE9"
3317
- }
3318
- }
3319
- }, {
3320
- "content": ") ",
3321
- "props": {
3322
- "style": {
3323
- "color": "#D8DEE9FF"
3324
- }
3325
- }
3326
- }, {
3327
- "content": "define",
3328
- "props": {
3329
- "style": {
3330
- "color": "#88C0D0"
3331
- }
3332
- }
3333
- }, {
3334
- "content": "([]",
3335
- "props": {
3336
- "style": {
3337
- "color": "#D8DEE9FF"
3338
- }
3339
- }
3340
- }, {
3341
- "content": ",",
3342
- "props": {
3343
- "style": {
3344
- "color": "#ECEFF4"
3345
- }
3346
- }
3347
- }, {
3348
- "content": " ",
3349
- "props": {
3350
- "style": {
3351
- "color": "#D8DEE9FF"
3352
- }
3353
- }
3354
- }, {
3355
- "content": "factory",
3356
- "props": {
3357
- "style": {
3358
- "color": "#D8DEE9"
3359
- }
3360
- }
3361
- }, {
3362
- "content": ")",
3363
- "props": {
3364
- "style": {
3365
- "color": "#D8DEE9FF"
3366
- }
3367
- }
3368
- }, {
3369
- "content": ";",
3370
- "props": {
3371
- "style": {
3372
- "color": "#81A1C1"
3373
- }
3374
- }
3375
- }]
3376
- }, {
3377
- "tokens": [{
3378
- "content": " ",
3379
- "props": {
3380
- "style": {
3381
- "color": "#D8DEE9FF"
3382
- }
3383
- }
3384
- }, {
3385
- "content": "else",
3386
- "props": {
3387
- "style": {
3388
- "color": "#81A1C1"
3389
- }
3390
- }
3391
- }, {
3392
- "content": " ",
3393
- "props": {
3394
- "style": {
3395
- "color": "#D8DEE9FF"
3396
- }
3397
- }
3398
- }, {
3399
- "content": "if",
3400
- "props": {
3401
- "style": {
3402
- "color": "#81A1C1"
3403
- }
3404
- }
3405
- }, {
3406
- "content": " (",
3407
- "props": {
3408
- "style": {
3409
- "color": "#D8DEE9FF"
3410
- }
3411
- }
3412
- }]
3413
- }, {
3414
- "tokens": [{
3415
- "content": " (",
3416
- "props": {
3417
- "style": {
3418
- "color": "#D8DEE9FF"
3419
- }
3420
- }
3421
- }, {
3422
- "content": "global",
3423
- "props": {
3424
- "style": {
3425
- "color": "#D8DEE9"
3426
- }
3427
- }
3428
- }, {
3429
- "content": " ",
3430
- "props": {
3431
- "style": {
3432
- "color": "#D8DEE9FF"
3433
- }
3434
- }
3435
- }, {
3436
- "content": "=",
3437
- "props": {
3438
- "style": {
3439
- "color": "#81A1C1"
3440
- }
3441
- }
3442
- }, {
3443
- "content": " ",
3444
- "props": {
3445
- "style": {
3446
- "color": "#D8DEE9FF"
3447
- }
3448
- }
3449
- }, {
3450
- "content": "typeof",
3451
- "props": {
3452
- "style": {
3453
- "color": "#81A1C1"
3454
- }
3455
- }
3456
- }, {
3457
- "content": " ",
3458
- "props": {
3459
- "style": {
3460
- "color": "#D8DEE9FF"
3461
- }
3462
- }
3463
- }, {
3464
- "content": "globalThis",
3465
- "props": {
3466
- "style": {
3467
- "color": "#D8DEE9"
3468
- }
3469
- }
3470
- }, {
3471
- "content": " ",
3472
- "props": {
3473
- "style": {
3474
- "color": "#D8DEE9FF"
3475
- }
3476
- }
3477
- }, {
3478
- "content": "!==",
3479
- "props": {
3480
- "style": {
3481
- "color": "#81A1C1"
3482
- }
3483
- }
3484
- }, {
3485
- "content": " ",
3486
- "props": {
3487
- "style": {
3488
- "color": "#D8DEE9FF"
3489
- }
3490
- }
3491
- }, {
3492
- "content": "'",
3493
- "props": {
3494
- "style": {
3495
- "color": "#ECEFF4"
3496
- }
3497
- }
3498
- }, {
3499
- "content": "undefined",
3500
- "props": {
3501
- "style": {
3502
- "color": "#A3BE8C"
3503
- }
3504
- }
3505
- }, {
3506
- "content": "'",
3507
- "props": {
3508
- "style": {
3509
- "color": "#ECEFF4"
3510
- }
3511
- }
3512
- }, {
3513
- "content": " ",
3514
- "props": {
3515
- "style": {
3516
- "color": "#D8DEE9FF"
3517
- }
3518
- }
3519
- }, {
3520
- "content": "?",
3521
- "props": {
3522
- "style": {
3523
- "color": "#81A1C1"
3524
- }
3525
- }
3526
- }, {
3527
- "content": " ",
3528
- "props": {
3529
- "style": {
3530
- "color": "#D8DEE9FF"
3531
- }
3532
- }
3533
- }, {
3534
- "content": "globalThis",
3535
- "props": {
3536
- "style": {
3537
- "color": "#D8DEE9"
3538
- }
3539
- }
3540
- }, {
3541
- "content": " ",
3542
- "props": {
3543
- "style": {
3544
- "color": "#D8DEE9FF"
3545
- }
3546
- }
3547
- }, {
3548
- "content": ":",
3549
- "props": {
3550
- "style": {
3551
- "color": "#81A1C1"
3552
- }
3553
- }
3554
- }, {
3555
- "content": " ",
3556
- "props": {
3557
- "style": {
3558
- "color": "#D8DEE9FF"
3559
- }
3560
- }
3561
- }, {
3562
- "content": "global",
3563
- "props": {
3564
- "style": {
3565
- "color": "#D8DEE9"
3566
- }
3567
- }
3568
- }, {
3569
- "content": " ",
3570
- "props": {
3571
- "style": {
3572
- "color": "#D8DEE9FF"
3573
- }
3574
- }
3575
- }, {
3576
- "content": "||",
3577
- "props": {
3578
- "style": {
3579
- "color": "#81A1C1"
3580
- }
3581
- }
3582
- }, {
3583
- "content": " ",
3584
- "props": {
3585
- "style": {
3586
- "color": "#D8DEE9FF"
3587
- }
3588
- }
3589
- }, {
3590
- "content": "self",
3591
- "props": {
3592
- "style": {
3593
- "color": "#D8DEE9"
3594
- }
3595
- }
3596
- }, {
3597
- "content": ")",
3598
- "props": {
3599
- "style": {
3600
- "color": "#D8DEE9FF"
3601
- }
3602
- }
3603
- }]
3604
- }, {
3605
- "tokens": [{
3606
- "content": " )",
3607
- "props": {
3608
- "style": {
3609
- "color": "#D8DEE9FF"
3610
- }
3611
- }
3612
- }]
3613
- }, {
3614
- "tokens": [{
3615
- "content": " ",
3616
- "props": {
3617
- "style": {
3618
- "color": "#D8DEE9FF"
3619
- }
3620
- }
3621
- }, {
3622
- "content": "factory",
3623
- "props": {
3624
- "style": {
3625
- "color": "#88C0D0"
3626
- }
3627
- }
3628
- }, {
3629
- "content": "()",
3630
- "props": {
3631
- "style": {
3632
- "color": "#D8DEE9FF"
3633
- }
3634
- }
3635
- }, {
3636
- "content": ";",
3637
- "props": {
3638
- "style": {
3639
- "color": "#81A1C1"
3640
- }
3641
- }
3642
- }]
3643
- }, {
3644
- "tokens": [{
3645
- "content": "}",
3646
- "props": {
3647
- "style": {
3648
- "color": "#ECEFF4"
3649
- }
3650
- }
3651
- }, {
3652
- "content": ")(",
3653
- "props": {
3654
- "style": {
3655
- "color": "#D8DEE9FF"
3656
- }
3657
- }
3658
- }, {
3659
- "content": "this",
3660
- "props": {
3661
- "style": {
3662
- "color": "#81A1C1"
3663
- }
3664
- }
3665
- }, {
3666
- "content": ",",
3667
- "props": {
3668
- "style": {
3669
- "color": "#ECEFF4"
3670
- }
3671
- }
3672
- }, {
3673
- "content": " ",
3674
- "props": {
3675
- "style": {
3676
- "color": "#D8DEE9FF"
3677
- }
3678
- }
3679
- }, {
3680
- "content": "function",
3681
- "props": {
3682
- "style": {
3683
- "color": "#81A1C1"
3684
- }
3685
- }
3686
- }, {
3687
- "content": " ",
3688
- "props": {
3689
- "style": {
3690
- "color": "#D8DEE9FF"
3691
- }
3692
- }
3693
- }, {
3694
- "content": "()",
3695
- "props": {
3696
- "style": {
3697
- "color": "#ECEFF4"
3698
- }
3699
- }
3700
- }, {
3701
- "content": " ",
3702
- "props": {
3703
- "style": {
3704
- "color": "#D8DEE9FF"
3705
- }
3706
- }
3707
- }, {
3708
- "content": "{",
3709
- "props": {
3710
- "style": {
3711
- "color": "#ECEFF4"
3712
- }
3713
- }
3714
- }]
3715
- }, {
3716
- "tokens": [{
3717
- "content": " ",
3718
- "props": {
3719
- "style": {
3720
- "color": "#D8DEE9FF"
3721
- }
3722
- }
3723
- }, {
3724
- "content": "'",
3725
- "props": {
3726
- "style": {
3727
- "color": "#ECEFF4"
3728
- }
3729
- }
3730
- }, {
3731
- "content": "use strict",
3732
- "props": {
3733
- "style": {
3734
- "color": "#A3BE8C"
3735
- }
3736
- }
3737
- }, {
3738
- "content": "'",
3739
- "props": {
3740
- "style": {
3741
- "color": "#ECEFF4"
3742
- }
3743
- }
3744
- }, {
3745
- "content": ";",
3746
- "props": {
3747
- "style": {
3748
- "color": "#81A1C1"
3749
- }
3750
- }
3751
- }]
3752
- }, {
3753
- "tokens": [{
3754
- "content": " ",
3755
- "props": {
3756
- "style": {
3757
- "color": "#D8DEE9FF"
3758
- }
3759
- }
3760
- }, {
3761
- "content": "var",
3762
- "props": {
3763
- "style": {
3764
- "color": "#81A1C1"
3765
- }
3766
- }
3767
- }, {
3768
- "content": " ",
3769
- "props": {
3770
- "style": {
3771
- "color": "#D8DEE9FF"
3772
- }
3773
- }
3774
- }, {
3775
- "content": "bg_default",
3776
- "props": {
3777
- "style": {
3778
- "color": "#D8DEE9"
3779
- }
3780
- }
3781
- }, {
3782
- "content": " ",
3783
- "props": {
3784
- "style": {
3785
- "color": "#D8DEE9FF"
3786
- }
3787
- }
3788
- }, {
3789
- "content": "=",
3790
- "props": {
3791
- "style": {
3792
- "color": "#81A1C1"
3793
- }
3794
- }
3795
- }, {
3796
- "content": " ",
3797
- "props": {
3798
- "style": {
3799
- "color": "#D8DEE9FF"
3800
- }
3801
- }
3802
- }, {
3803
- "content": "'",
3804
- "props": {
3805
- "style": {
3806
- "color": "#ECEFF4"
3807
- }
3808
- }
3809
- }, {
3810
- "content": "http://cdn/assets/bg.13e2aba2.png",
3811
- "props": {
3812
- "style": {
3813
- "color": "#A3BE8C"
3814
- }
3815
- }
3816
- }, {
3817
- "content": "'",
3818
- "props": {
3819
- "style": {
3820
- "color": "#ECEFF4"
3821
- }
3822
- }
3823
- }, {
3824
- "content": ";",
3825
- "props": {
3826
- "style": {
3827
- "color": "#81A1C1"
3828
- }
3829
- }
3830
- }]
3831
- }, {
3832
- "tokens": [{
3833
- "content": " ",
3834
- "props": {
3835
- "style": {
3836
- "color": "#ECEFF4"
3837
- }
3838
- }
3839
- }, {
3840
- "content": "// src/asset.tsx",
3841
- "props": {
3842
- "style": {
3843
- "color": "#616E88"
3844
- }
3845
- }
3846
- }]
3847
- }, {
3848
- "tokens": [{
3849
- "content": " ",
3850
- "props": {
3851
- "style": {
3852
- "color": "#D8DEE9FF"
3853
- }
3854
- }
3855
- }, {
3856
- "content": "console",
3857
- "props": {
3858
- "style": {
3859
- "color": "#D8DEE9"
3860
- }
3861
- }
3862
- }, {
3863
- "content": ".",
3864
- "props": {
3865
- "style": {
3866
- "color": "#ECEFF4"
3867
- }
3868
- }
3869
- }, {
3870
- "content": "info",
3871
- "props": {
3872
- "style": {
3873
- "color": "#88C0D0"
3874
- }
3875
- }
3876
- }, {
3877
- "content": "(",
3878
- "props": {
3879
- "style": {
3880
- "color": "#D8DEE9FF"
3881
- }
3882
- }
3883
- }, {
3884
- "content": "bg_default",
3885
- "props": {
3886
- "style": {
3887
- "color": "#D8DEE9"
3888
- }
3889
- }
3890
- }, {
3891
- "content": ")",
3892
- "props": {
3893
- "style": {
3894
- "color": "#D8DEE9FF"
3895
- }
3896
- }
3897
- }, {
3898
- "content": ";",
3899
- "props": {
3900
- "style": {
3901
- "color": "#81A1C1"
3902
- }
3903
- }
3904
- }]
3905
- }, {
3906
- "tokens": [{
3907
- "content": "}",
3908
- "props": {
3909
- "style": {
3910
- "color": "#ECEFF4"
3911
- }
3912
- }
3913
- }, {
3914
- "content": ")",
3915
- "props": {
3916
- "style": {
3917
- "color": "#D8DEE9FF"
3918
- }
3919
- }
3920
- }, {
3921
- "content": ";",
3922
- "props": {
3923
- "style": {
3924
- "color": "#81A1C1"
3925
- }
3926
- }
3927
- }]
3928
- }],
3929
- "lang": "js"
3930
- },
3931
- "annotations": []
3932
- }],
3933
- "southPanel": undefined
3934
- }],
3935
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
3936
- children: (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(CH.CodeSlot, {})
3937
- }), (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
3938
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.p, {
3939
- children: "项目源代码。"
3940
- }), (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(CH.CodeSlot, {})]
3941
- }), (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
3942
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.p, {
3943
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
3944
- children: "modern.config"
3945
- }), " 配置为。"]
3946
- }), (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(CH.CodeSlot, {})]
3947
- }), (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
3948
- children: [(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components.p, {
3949
- children: ["如果 ", (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_components.code, {
3950
- children: "bg.png"
3951
- }), " 的大小大于 10 kb,则此时产物内容为。"]
3952
- }), (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(CH.CodeSlot, {})]
3953
- })]
3954
- })]
3955
- });
3956
- }
3957
- function MDXContent(props = {}) {
3958
- const {wrapper: MDXLayout} = props.components || ({});
3959
- return MDXLayout ? (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(MDXLayout, Object.assign({}, props, {
3960
- children: (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_createMdxContent, props)
3961
- })) : _createMdxContent(props);
3962
- }
3963
- /* harmony default export */ __webpack_exports__["default"] = (MDXContent);
3964
- function _missingMdxReference(id, component, place) {
3965
- throw new Error("Expected " + (component ? "component" : "object") + " `" + id + "` to be defined: you likely forgot to import, pass, or provide it." + (place ? "\nIt’s referenced in your code at `" + place + "` in `/Users/bytedance/github/targeral/modern-dev/website/module-tools/docs/zh/guide/advance/asset.mdx`" : ""));
3966
- }
3967
-
3968
-
3969
- /***/ })
3970
-
3971
- }]);
3972
- //# sourceMappingURL=zh_guide_advance_asset.js.map