Are you over 18 and want to see adult content?
More Annotations
A complete backup of letstalkaboutgreen.com
Are you over 18 and want to see adult content?
A complete backup of taufan-fhm.blogspot.com
Are you over 18 and want to see adult content?
A complete backup of mathoehrlein.weebly.com
Are you over 18 and want to see adult content?
A complete backup of rasc2018canada.com
Are you over 18 and want to see adult content?
A complete backup of simsworkshop.net
Are you over 18 and want to see adult content?
Favourite Annotations
A complete backup of geekgirlpenpals.com
Are you over 18 and want to see adult content?
A complete backup of thoughtspheres.com
Are you over 18 and want to see adult content?
A complete backup of crowdworknews.com
Are you over 18 and want to see adult content?
Text
VITEJS.DEV - HOME
💡 Instant Server Start. On demand file serving over native ESM, no bundling required! âš¡ï¸ Lightning Fast HMR. Hot Module Replacement (HMR) that stays fast regardless of app size.GETTING STARTED
Vite (French word for "fast", pronounced /vit/) is a build tool that aims to provide a faster and leaner development experience for modern web projects. It consists of two major parts: A dev server that provides rich feature enhancements over native ES modules, for example extremely fast Hot Module Replacement (HMR).CN.VITEJS.DEV
💡 æžé€Ÿçš„æœåŠ¡å¯åŠ¨. 使用原生 esm æ–‡ä»¶ï¼Œæ— éœ€æ‰“åŒ…! âš¡ï¸ è½»é‡å¿«é€Ÿçš„çƒé‡è½½. æ— è®ºåº”ç”¨ç¨‹åºå¤§å°å¦‚何,都始终æžå¿«çš„模å—çƒ ENV VARIABLES AND MODES In your app, you can render the title using import. meta.env.VITE_APP_TITLE.. However, it is important to understand that mode is a wider concept than just development vs. production. A typical example is you may want to have a "staging" mode where it should have production-like behavior, but with slightly different env variables from production.FEATURES | VITE
#CSS. Importing .css files will inject its content to the page via a tag with HMR support. You can also retrieve the processed CSS as a string as the module's default export. # @import Inlining and Rebasing Vite is pre-configured to support CSS @import inlining via postcss-import.Vite aliases are also respected for CSS @import.In addition, all CSS url() references, even if the importedCONFIGURING VITE
When running vite from the command line, Vite will automatically try to resolve a config file named vite.config.js inside project root. The most basic config file looks like this: Note Vite supports using ES modules syntax in the config file even if the project is not using native Node ESM via type: "module". DEPENDENCY PRE-BUNDLING Vite caches the pre-bundled dependencies in node_modules/.vite. It determines whether it needs to re-run the pre-bundling step based on a few sources: The dependencies list in your package.json. Package manager lockfiles, e.g. package-lock.json, yarn.lock, or pnpm-lock.yaml. Relevant fields in your vite.config.js, if present. STATIC ASSET HANDLING Importing a static asset will return the resolved public URL when it is served: For example, imgUrl will be /img.png during development, and become /assets/img.2d8efhg.png in the production build. The behavior is similar to webpack's file-loader. The difference is that the import can be either using absolute public paths (based on projectroot
SERVER-SIDE RENDERING Server-Side Rendering. Experimental. SSR support is still experimental and you may encounter bugs and unsupported use cases. Proceed at your own risk. Note. SSR specifically refers to front-end frameworks (for example React, Preact, Vue, and Svelte) that support running the same application in Node.js, pre-rendering it to HTML, and finallyé…ç½® VITE
当以命令行方å¼è¿è¡Œ vite 时,Vite ä¼šè‡ªåŠ¨è§£æž é¡¹ç›®æ ¹ç›®å½• 下å为 vite.config.js 的文件。. 最基础的é…ç½®æ–‡ä»¶æ˜¯è¿™æ ·çš„ï¼š. export default { } 注æ„,å³ä½¿é¡¹ç›®æ²¡æœ‰åœ¨ package.json ä¸å¼€å¯ type: "module" ,Vite 也支æŒåœ¨é…置文件ä¸ä½¿ç”¨ ESM è¯æ³•ã€‚. 在这ç§æƒ…况下,é…ç½®æ–‡ä»¶æ˜¯åœ¨åŠ è½½VITEJS.DEV - HOME
💡 Instant Server Start. On demand file serving over native ESM, no bundling required! âš¡ï¸ Lightning Fast HMR. Hot Module Replacement (HMR) that stays fast regardless of app size.GETTING STARTED
Vite (French word for "fast", pronounced /vit/) is a build tool that aims to provide a faster and leaner development experience for modern web projects. It consists of two major parts: A dev server that provides rich feature enhancements over native ES modules, for example extremely fast Hot Module Replacement (HMR).CN.VITEJS.DEV
💡 æžé€Ÿçš„æœåŠ¡å¯åŠ¨. 使用原生 esm æ–‡ä»¶ï¼Œæ— éœ€æ‰“åŒ…! âš¡ï¸ è½»é‡å¿«é€Ÿçš„çƒé‡è½½. æ— è®ºåº”ç”¨ç¨‹åºå¤§å°å¦‚何,都始终æžå¿«çš„模å—çƒ ENV VARIABLES AND MODES In your app, you can render the title using import. meta.env.VITE_APP_TITLE.. However, it is important to understand that mode is a wider concept than just development vs. production. A typical example is you may want to have a "staging" mode where it should have production-like behavior, but with slightly different env variables from production.FEATURES | VITE
#CSS. Importing .css files will inject its content to the page via a tag with HMR support. You can also retrieve the processed CSS as a string as the module's default export. # @import Inlining and Rebasing Vite is pre-configured to support CSS @import inlining via postcss-import.Vite aliases are also respected for CSS @import.In addition, all CSS url() references, even if the importedCONFIGURING VITE
When running vite from the command line, Vite will automatically try to resolve a config file named vite.config.js inside project root. The most basic config file looks like this: Note Vite supports using ES modules syntax in the config file even if the project is not using native Node ESM via type: "module". DEPENDENCY PRE-BUNDLING Vite caches the pre-bundled dependencies in node_modules/.vite. It determines whether it needs to re-run the pre-bundling step based on a few sources: The dependencies list in your package.json. Package manager lockfiles, e.g. package-lock.json, yarn.lock, or pnpm-lock.yaml. Relevant fields in your vite.config.js, if present. STATIC ASSET HANDLING Importing a static asset will return the resolved public URL when it is served: For example, imgUrl will be /img.png during development, and become /assets/img.2d8efhg.png in the production build. The behavior is similar to webpack's file-loader. The difference is that the import can be either using absolute public paths (based on projectroot
SERVER-SIDE RENDERING Server-Side Rendering. Experimental. SSR support is still experimental and you may encounter bugs and unsupported use cases. Proceed at your own risk. Note. SSR specifically refers to front-end frameworks (for example React, Preact, Vue, and Svelte) that support running the same application in Node.js, pre-rendering it to HTML, and finallyé…ç½® VITE
当以命令行方å¼è¿è¡Œ vite 时,Vite ä¼šè‡ªåŠ¨è§£æž é¡¹ç›®æ ¹ç›®å½• 下å为 vite.config.js 的文件。. 最基础的é…ç½®æ–‡ä»¶æ˜¯è¿™æ ·çš„ï¼š. export default { } 注æ„,å³ä½¿é¡¹ç›®æ²¡æœ‰åœ¨ package.json ä¸å¼€å¯ type: "module" ,Vite 也支æŒåœ¨é…置文件ä¸ä½¿ç”¨ ESM è¯æ³•ã€‚. 在这ç§æƒ…况下,é…ç½®æ–‡ä»¶æ˜¯åœ¨åŠ è½½PLUGINS | VITE
NOTE. Vite aims to provide out-of-the-box support for common web development patterns. Before searching for a Vite or Compatible Rollup plugin, check out the Features Guide.A lot of the cases where a plugin would be needed in a Rollup project are already covered in Vite. BUILDING FOR PRODUCTION Building for Production. When it is time to deploy your app for production, simply run the vite build command. By default, it uses /index.html as the build entry point, and produces an application bundle that is suitable to be served over a static hosting service. Check out the Deploying a Static Site for guides about popularservices.
DEPENDENCY PRE-BUNDLING Vite caches the pre-bundled dependencies in node_modules/.vite. It determines whether it needs to re-run the pre-bundling step based on a few sources: The dependencies list in your package.json. Package manager lockfiles, e.g. package-lock.json, yarn.lock, or pnpm-lock.yaml. Relevant fields in your vite.config.js, if present.ANNOUNCING VITE 2.0
Announcing Vite 2.0. Today we are excited to announce the official release of Vite 2.0! Vite (French word for "fast", pronounced /vit/) is a new kind of build tool for frontend web development. Think a pre-configured dev server + bundler combo, but leaner and faster. It leverages browser's native ES modules support and tools written incompile
PLUGIN API | VITE
Plugin API. Vite plugins extends Rollup's well-designed plugin interface with a few extra Vite-specific options. As a result, you can write a Vite plugin once and have it work for both dev and build. It is recommended to go through Rollup's plugin documentation first before reading the sections below. DEPLOYING A STATIC SITE Create a Heroku account by signing up. Run heroku login and fill in your Heroku credentials: $ heroku login. Create a file called static.json in the root of your project with the below content: static.json: { "root": "./dist" } This is the configuration of your site; read more at heroku-buildpack-static. 开始 | VITE 官方ä¸æ–‡æ–‡æ¡£ Vite (法è¯æ„为 "快速的",å‘音 /vit/) 是一ç§æ–°åž‹å‰ç«¯æž„建工具,能够显著æå‡å‰ç«¯å¼€å‘体验。. 它主è¦ç”±ä¸¤éƒ¨åˆ†ç»„æˆï¼š. 一个开å‘æœåŠ¡å™¨ï¼Œå®ƒåŸºäºŽ 原生 ES æ¨¡å— æ供了 丰富的内建功能 ,如速度快到惊人的 模å—çƒæ›´æ–°ï¼ˆHMR) 。. 一套构建指令,它使用 Rollup æ‰“åŒ…ä½ æ¯”è¾ƒ | VITE 官方ä¸æ–‡æ–‡æ¡£ #比较 # Snowpack Snowpack 也是一个与 Vite å分类似的éžæž„建å¼åŽŸç”Ÿ ESM å¼€å‘æœåŠ¡å™¨ã€‚ 除了ä¸åŒçš„å®žçŽ°ç»†èŠ‚å¤–ï¼Œè¿™ä¸¤ä¸ªé¡¹ç›®åœ¨æŠ€æœ¯ä¸Šæ¯”ä¼ ç»Ÿå·¥å…·æœ‰å¾ˆå¤šå…±åŒä¼˜åŠ¿ã€‚Vite çš„ä¾èµ–预绑定也å—到了 Snowpack v1(现在是 esinstall)的å¯å‘。 这两个项目之间的一些主è¦åŒºåˆ«æ˜¯ï¼šæž„建生产版本
构建生产版本.
当需è¦å°†åº”用部署到生产环境时,åªéœ€è¿è¡Œ vite build 命令。. 默认情况下,它使用 /index.html 作为其构建入å£ç‚¹ï¼Œå¹¶ç”Ÿæˆèƒ½å¤Ÿé™æ€éƒ¨ç½²çš„应用程åºåŒ…。. 请查阅 部署é™æ€ç«™ç‚¹ 获å–常è§æœåŠ¡çš„部署指引。.æœåŠ¡ç«¯æ¸²æŸ“
一个典型的 SSR 应用应该有如下的æºæ–‡ä»¶ç»“构:. - index.html - src/ - main.js # å¯¼å‡ºçŽ¯å¢ƒæ— å…³çš„ï¼ˆé€šç”¨çš„ï¼‰åº”ç”¨ä»£ç - entry-client.js # 将应用挂载到一个 DOM å…ƒç´ ä¸Š - entry-server.js # 使用æŸæ¡†æž¶çš„ SSR API 渲染该应用. index.html 将需è¦å¼•ç”¨ entry-client.js 并包å«ä¸€ä¸ªå ä½æ ‡è®°ä¾›ç»™VITEJS.DEV - HOME
💡 Instant Server Start. On demand file serving over native ESM, no bundling required! âš¡ï¸ Lightning Fast HMR. Hot Module Replacement (HMR) that stays fast regardless of app size.GETTING STARTED
Vite (French word for "fast", pronounced /vit/) is a build tool that aims to provide a faster and leaner development experience for modern web projects. It consists of two major parts: A dev server that provides rich feature enhancements over native ES modules, for example extremely fast Hot Module Replacement (HMR).PLUGINS | VITE
Vite aims to provide out-of-the-box support for common web development patterns. Before searching for a Vite or Compatible Rollup plugin, check out the Features Guide. A lot of the cases where a plugin would be needed in a Rollup project are already covered in Vite.CN.VITEJS.DEV
💡 æžé€Ÿçš„æœåŠ¡å¯åŠ¨. 使用原生 esm æ–‡ä»¶ï¼Œæ— éœ€æ‰“åŒ…! âš¡ï¸ è½»é‡å¿«é€Ÿçš„çƒé‡è½½. æ— è®ºåº”ç”¨ç¨‹åºå¤§å°å¦‚何,都始终æžå¿«çš„模å—çƒFEATURES | VITE
#CSS. Importing .css files will inject its content to the page via a tag with HMR support. You can also retrieve the processed CSS as a string as the module's default export. # @import Inlining and Rebasing Vite is pre-configured to support CSS @import inlining via postcss-import.Vite aliases are also respected for CSS @import.In addition, all CSS url() references, even if the imported ENV VARIABLES AND MODES In your app, you can render the title using import. meta.env.VITE_APP_TITLE.. However, it is important to understand that mode is a wider concept than just development vs. production. A typical example is you may want to have a "staging" mode where it should have production-like behavior, but with slightly different env variables from production.CONFIGURING VITE
When running vite from the command line, Vite will automatically try to resolve a config file named vite.config.js inside project root. The most basic config file looks like this: Note Vite supports using ES modules syntax in the config file even if the project is not using native Node ESM via type: "module". WHY VITE | VITESEE MORE ON VITEJS.DEV BUILDING FOR PRODUCTION Building for Production. When it is time to deploy your app for production, simply run the vite build command. By default, it uses /index.html as the build entry point, and produces an application bundle that is suitable to be served over a static hosting service. Check out the Deploying a Static Site for guides about popularservices.
从 V1 è¿ç§»
#从 v1 è¿ç§» # é…置项å˜åŒ– ä»¥ä¸‹é€‰é¡¹å·²è¢«åˆ é™¤ï¼Œåº”é€šè¿‡ æ’件 实现:. resolvers; transforms; indexHtmlTransforms; jsx å’Œ enableEsbuild éƒ½å·²è¢«åˆ é™¤ï¼Œè¯·ä½¿ç”¨æ–°çš„ esbuild 选项。. CSS 相关选项 都被包å«åœ¨ css å—段下。. 所有 用于构建的选项 现在都在 build å—段下。. rollupInputOptions å’Œ rollupOutputOptions å·²ç»è¢«build.rollupOptions
VITEJS.DEV - HOME
💡 Instant Server Start. On demand file serving over native ESM, no bundling required! âš¡ï¸ Lightning Fast HMR. Hot Module Replacement (HMR) that stays fast regardless of app size.GETTING STARTED
Vite (French word for "fast", pronounced /vit/) is a build tool that aims to provide a faster and leaner development experience for modern web projects. It consists of two major parts: A dev server that provides rich feature enhancements over native ES modules, for example extremely fast Hot Module Replacement (HMR).PLUGINS | VITE
Vite aims to provide out-of-the-box support for common web development patterns. Before searching for a Vite or Compatible Rollup plugin, check out the Features Guide. A lot of the cases where a plugin would be needed in a Rollup project are already covered in Vite.CN.VITEJS.DEV
💡 æžé€Ÿçš„æœåŠ¡å¯åŠ¨. 使用原生 esm æ–‡ä»¶ï¼Œæ— éœ€æ‰“åŒ…! âš¡ï¸ è½»é‡å¿«é€Ÿçš„çƒé‡è½½. æ— è®ºåº”ç”¨ç¨‹åºå¤§å°å¦‚何,都始终æžå¿«çš„模å—çƒFEATURES | VITE
#CSS. Importing .css files will inject its content to the page via a tag with HMR support. You can also retrieve the processed CSS as a string as the module's default export. # @import Inlining and Rebasing Vite is pre-configured to support CSS @import inlining via postcss-import.Vite aliases are also respected for CSS @import.In addition, all CSS url() references, even if the imported ENV VARIABLES AND MODES In your app, you can render the title using import. meta.env.VITE_APP_TITLE.. However, it is important to understand that mode is a wider concept than just development vs. production. A typical example is you may want to have a "staging" mode where it should have production-like behavior, but with slightly different env variables from production.CONFIGURING VITE
When running vite from the command line, Vite will automatically try to resolve a config file named vite.config.js inside project root. The most basic config file looks like this: Note Vite supports using ES modules syntax in the config file even if the project is not using native Node ESM via type: "module". WHY VITE | VITESEE MORE ON VITEJS.DEV BUILDING FOR PRODUCTION Building for Production. When it is time to deploy your app for production, simply run the vite build command. By default, it uses /index.html as the build entry point, and produces an application bundle that is suitable to be served over a static hosting service. Check out the Deploying a Static Site for guides about popularservices.
从 V1 è¿ç§»
#从 v1 è¿ç§» # é…置项å˜åŒ– ä»¥ä¸‹é€‰é¡¹å·²è¢«åˆ é™¤ï¼Œåº”é€šè¿‡ æ’件 实现:. resolvers; transforms; indexHtmlTransforms; jsx å’Œ enableEsbuild éƒ½å·²è¢«åˆ é™¤ï¼Œè¯·ä½¿ç”¨æ–°çš„ esbuild 选项。. CSS 相关选项 都被包å«åœ¨ css å—段下。. 所有 用于构建的选项 现在都在 build å—段下。. rollupInputOptions å’Œ rollupOutputOptions å·²ç»è¢«build.rollupOptions
GETTING STARTED
Vite (French word for "fast", pronounced /vit/) is a build tool that aims to provide a faster and leaner development experience for modern web projects. It consists of two major parts: A dev server that provides rich feature enhancements over native ES modules, for example extremely fast Hot Module Replacement (HMR). COMPARISONS WITH OTHER NO-BUNDLER SOLUTIONS #Comparisons with Other No-Bundler Solutions # Snowpack Snowpack is also a no-bundle native ESM dev server that is very similar in scope to Vite. Aside from different implementation details, the two projects share a lot in terms of technical advantages over traditional tooling. STATIC ASSET HANDLING Importing a static asset will return the resolved public URL when it is served: For example, imgUrl will be /img.png during development, and become /assets/img.2d8efhg.png in the production build. The behavior is similar to webpack's file-loader. The difference is that the import can be either using absolute public paths (based on projectroot
USING PLUGINS
Using Plugins. Vite can be extended using plugins, which are based on Rollup's well-designed plugin interface with a few extra Vite-specific options. This means that Vite users can rely on the mature ecosystem of Rollup plugins, while also being able to extend the dev server and SSR functionality as DEPENDENCY PRE-BUNDLING Vite caches the pre-bundled dependencies in node_modules/.vite. It determines whether it needs to re-run the pre-bundling step based on a few sources: The dependencies list in your package.json. Package manager lockfiles, e.g. package-lock.json, yarn.lock, or pnpm-lock.yaml. Relevant fields in your vite.config.js, if present.ANNOUNCING VITE 2.0
Announcing Vite 2.0. Today we are excited to announce the official release of Vite 2.0! Vite (French word for "fast", pronounced /vit/) is a new kind of build tool for frontend web development. Think a pre-configured dev server + bundler combo, but leaner and faster. It leverages browser's native ES modules support and tools written incompile
PLUGIN API | VITE
Plugin API. Vite plugins extends Rollup's well-designed plugin interface with a few extra Vite-specific options. As a result, you can write a Vite plugin once and have it work for both dev and build. It is recommended to go through Rollup's plugin documentation first before reading the sections below. SERVER-SIDE RENDERING Server-Side Rendering. Experimental. SSR support is still experimental and you may encounter bugs and unsupported use cases. Proceed at your own risk. Note. SSR specifically refers to front-end frameworks (for example React, Preact, Vue, and Svelte) that support running the same application in Node.js, pre-rendering it to HTML, and finally 开始 | VITE 官方ä¸æ–‡æ–‡æ¡£ Vite (法è¯æ„为 "快速的",å‘音 /vit/) 是一ç§æ–°åž‹å‰ç«¯æž„建工具,能够显著æå‡å‰ç«¯å¼€å‘体验。. 它主è¦ç”±ä¸¤éƒ¨åˆ†ç»„æˆï¼š. 一个开å‘æœåŠ¡å™¨ï¼Œå®ƒåŸºäºŽ 原生 ES æ¨¡å— æ供了 丰富的内建功能 ,如速度快到惊人的 模å—çƒæ›´æ–°ï¼ˆHMR) 。. 一套构建指令,它使用 Rollup 打包ä½é™æ€èµ„æºå¤„ç†
url () 在 CSS ä¸çš„引用也以åŒæ ·çš„æ–¹å¼å¤„ç†ã€‚. 如果 Vite 使用了 Vue æ’件,Vue SFC 模æ¿ä¸çš„资æºå¼•ç”¨éƒ½å°†è‡ªåŠ¨è½¬æ¢ä¸ºå¯¼å…¥ã€‚. 常è§çš„图åƒã€åª’体和å—体文件类型被自动检测为资æºã€‚. ä½ å¯ä»¥ä½¿ç”¨ assetsInclude 选项 扩展内部列表。. 引用的资æºä½œä¸ºæž„建资æºå›¾çš„一部分包括VITEJS.DEV - HOME
💡 Instant Server Start. On demand file serving over native ESM, no bundling required! âš¡ï¸ Lightning Fast HMR. Hot Module Replacement (HMR) that stays fast regardless of app size.GETTING STARTED
Next Generation Frontend Tooling. You can specify additional CLI options like --port or --https.For a full list of CLI options, run npx vite --help in your project. # Using Unreleased Commits If you can't wait for a new release to test the latest features, you will need to clone the vite repo to your local machine and then build and link it yourself (Yarn 1.x is required):PLUGINS | VITE
NOTE. Vite aims to provide out-of-the-box support for common web development patterns. Before searching for a Vite or Compatible Rollup plugin, check out the Features Guide.A lot of the cases where a plugin would be needed in a Rollup project are already covered in Vite.FEATURES | VITE
#CSS. Importing .css files will inject its content to the page via a tag with HMR support. You can also retrieve the processed CSS as a string as the module's default export. # @import Inlining and Rebasing Vite is pre-configured to support CSS @import inlining via postcss-import.Vite aliases are also respected for CSS @import.In addition, all CSS url() references, even if the importedCN.VITEJS.DEV
💡 æžé€Ÿçš„æœåŠ¡å¯åŠ¨. 使用原生 esm æ–‡ä»¶ï¼Œæ— éœ€æ‰“åŒ…! âš¡ï¸ è½»é‡å¿«é€Ÿçš„çƒé‡è½½. æ— è®ºåº”ç”¨ç¨‹åºå¤§å°å¦‚何,都始终æžå¿«çš„模å—çƒ ENV VARIABLES AND MODES In your app, you can render the title using import. meta.env.VITE_APP_TITLE.. However, it is important to understand that mode is a wider concept than just development vs. production. A typical example is you may want to have a "staging" mode where it should have production-like behavior, but with slightly different env variables from production.CONFIGURING VITE
#Configuring Vite # Config File # Config File Resolving When running vite from the command line, Vite will automatically try to resolve a config file named vite.config.js inside project root.. The most basic config file looks like this: WHY VITE | VITESEE MORE ON VITEJS.DEV BUILDING FOR PRODUCTION If you specify a different root, remember that __dirname will still be the folder of your vite.config.js file when resolving the input paths. Therfore, you will need to add your root entry to the arguments for resolve. # Library Mode When you are developing a browser-oriented library, you are likely spending most of the time on a test/demo page that imports your actual library.使用æ’件
查看 Plugins ç« èŠ‚ 获å–官方æ’件信æ¯ã€‚ 社区æ’件列表请å‚è§ awesome-vite。 而对于兼容的 Rollup æ’件,请查看 Vite Rollup æ’件 获å–一个带使用说明的兼容 Rollup 官方æ’件列表,若列表ä¸æ²¡æœ‰æ‰¾åˆ°ï¼Œåˆ™è¯·å‚阅 Rollup æ’ä»¶å…¼å®¹æ€§ç« èŠ‚ã€‚. ä½ ä¹Ÿå¯ä»¥ä½¿ç”¨æ¤ npm Vite æ’件æœç´¢é“¾æŽ¥ æ¥æ‰¾åˆ°ä¸€äº›éµå¾ªäº† 推è约定 çš„ ViteVITEJS.DEV - HOME
💡 Instant Server Start. On demand file serving over native ESM, no bundling required! âš¡ï¸ Lightning Fast HMR. Hot Module Replacement (HMR) that stays fast regardless of app size.GETTING STARTED
Next Generation Frontend Tooling. You can specify additional CLI options like --port or --https.For a full list of CLI options, run npx vite --help in your project. # Using Unreleased Commits If you can't wait for a new release to test the latest features, you will need to clone the vite repo to your local machine and then build and link it yourself (Yarn 1.x is required):PLUGINS | VITE
NOTE. Vite aims to provide out-of-the-box support for common web development patterns. Before searching for a Vite or Compatible Rollup plugin, check out the Features Guide.A lot of the cases where a plugin would be needed in a Rollup project are already covered in Vite.FEATURES | VITE
#CSS. Importing .css files will inject its content to the page via a tag with HMR support. You can also retrieve the processed CSS as a string as the module's default export. # @import Inlining and Rebasing Vite is pre-configured to support CSS @import inlining via postcss-import.Vite aliases are also respected for CSS @import.In addition, all CSS url() references, even if the importedCN.VITEJS.DEV
💡 æžé€Ÿçš„æœåŠ¡å¯åŠ¨. 使用原生 esm æ–‡ä»¶ï¼Œæ— éœ€æ‰“åŒ…! âš¡ï¸ è½»é‡å¿«é€Ÿçš„çƒé‡è½½. æ— è®ºåº”ç”¨ç¨‹åºå¤§å°å¦‚何,都始终æžå¿«çš„模å—çƒ ENV VARIABLES AND MODES In your app, you can render the title using import. meta.env.VITE_APP_TITLE.. However, it is important to understand that mode is a wider concept than just development vs. production. A typical example is you may want to have a "staging" mode where it should have production-like behavior, but with slightly different env variables from production.CONFIGURING VITE
#Configuring Vite # Config File # Config File Resolving When running vite from the command line, Vite will automatically try to resolve a config file named vite.config.js inside project root.. The most basic config file looks like this: WHY VITE | VITESEE MORE ON VITEJS.DEV BUILDING FOR PRODUCTION If you specify a different root, remember that __dirname will still be the folder of your vite.config.js file when resolving the input paths. Therfore, you will need to add your root entry to the arguments for resolve. # Library Mode When you are developing a browser-oriented library, you are likely spending most of the time on a test/demo page that imports your actual library.使用æ’件
查看 Plugins ç« èŠ‚ 获å–官方æ’件信æ¯ã€‚ 社区æ’件列表请å‚è§ awesome-vite。 而对于兼容的 Rollup æ’件,请查看 Vite Rollup æ’件 获å–一个带使用说明的兼容 Rollup 官方æ’件列表,若列表ä¸æ²¡æœ‰æ‰¾åˆ°ï¼Œåˆ™è¯·å‚阅 Rollup æ’ä»¶å…¼å®¹æ€§ç« èŠ‚ã€‚. ä½ ä¹Ÿå¯ä»¥ä½¿ç”¨æ¤ npm Vite æ’件æœç´¢é“¾æŽ¥ æ¥æ‰¾åˆ°ä¸€äº›éµå¾ªäº† 推è约定 çš„ ViteGETTING STARTED
Next Generation Frontend Tooling. You can specify additional CLI options like --port or --https.For a full list of CLI options, run npx vite --help in your project. # Using Unreleased Commits If you can't wait for a new release to test the latest features, you will need to clone the vite repo to your local machine and then build and link it yourself (Yarn 1.x is required):USING PLUGINS
Next Generation Frontend Tooling. Check out the Plugins section for information about official plugins. Community plugins are listed in awesome-vite.For compatible Rollup plugins, check out Vite Rollup Plugins for a list of compatible official Rollup plugins with usage instructions or the Rollup Plugin Compatibility section in case it isnot listed there.
STATIC ASSET HANDLING For example, imgUrl will be /img.png during development, and become /assets/img.2d8efhg.png in the production build. The behavior is similar to webpack's file-loader.The difference is that the import can be either using absolute public paths (based on project root during dev) or relative paths. COMPARISONS WITH OTHER NO-BUNDLER SOLUTIONS #Comparisons with Other No-Bundler Solutions # Snowpack Snowpack is also a no-bundle native ESM dev server that is very similar in scope to Vite. Aside from different implementation details, the two projects share a lot in terms of technical advantages over traditional tooling.PLUGIN API | VITE
modules is an array of modules that are affected by the changed file. It's an array because a single file may map to multiple served modules (e.g. Vue SFCs). read is an async read function that returns the content of the file. This is provided because on some systems, the file change callback may fire too fast before the editor finishes updating the file and direct fs.readFile will return SERVER-SIDE RENDERING Low-level API. This is a low-level API meant for library and framework authors. If your goal is to create an application, make sure to check out the higher-level SSR plugins and tools at Awesome Vite SSR section first. That said, many applications are successfully built directly on top of Vite's native low-level API.ANNOUNCING VITE 2.0
#Announcing Vite 2.0. Today we are excited to announce the official release of Vite 2.0! Vite (French word for "fast", pronounced /vit/) is a new kind of build tool for frontend web development.Think a pre-configured dev server + bundler combo, but leaner and faster. DEPENDENCY PRE-BUNDLING #The Why. This is Vite performing what we call "dependency pre-bundling". This process serves two purposes: CommonJS and UMD compatibility: During development, Vite's dev serves all code as native ESM. Therefore, Vite must convert dependencies that are shipped as CommonJS or UMD into ESM first. 开始 | VITE 官方ä¸æ–‡æ–‡æ¡£ å¯ä»¥æŒ‡å®šé¢å¤–的命令行选项,如 --port 或 --https。è¿è¡Œ npx vite --help 获得完整的命令行选项列表。 # 使用未å‘布的功能 å¦‚æžœä½ è¿«ä¸åŠå¾…想è¦ä½“验最新的功能,å¯ä»¥è‡ªè¡Œå…‹éš† vite 仓库 到本地机器上然åŽè‡ªè¡Œå°†å…¶é“¾æŽ¥ï¼ˆå°†éœ€è¦Yarn 1.x):
é™æ€èµ„æºå¤„ç†
#é™æ€èµ„æºå¤„ç†. 相关: 公共基础路径 相关: assetsInclude é…置项 # 将资æºå¼•å…¥ä¸º URL æœåŠ¡æ—¶å¼•å…¥ä¸€ä¸ªé™æ€èµ„æºä¼šè¿”回解æžåŽçš„公共路径:Vite
Guide
Config
Plugins
Links
*
*
Discord Chat
*
Awesome Vite
*
DEV Community
*
Rollup Plugins Compat*
Changelog
Languages
*
English
*
简体ä¸æ–‡
GitHub
SearchK
Guide
Config
Plugins
Links
*
*
Discord Chat
*
Awesome Vite
*
DEV Community
*
Rollup Plugins Compat*
Changelog
Languages
*
English
*
简体ä¸æ–‡
GitHub
*
Guide
* Why Vite
* Getting Started
* Features
* Using Plugins
* Dependency Pre-Bundling * Static Asset Handling * Building for Production * Deploying a Static Site * Env Variables and Modes * Server-Side Rendering (SSR) * Backend Integration* Comparisons
* Migration from v1
*
APIs
* Plugin API
* HMR API
* JavaScript API
* Config Reference
Sponsors
VITE
Next Generation Frontend ToolingGet Started
Learn More
💡 INSTANT SERVER START On demand file serving over native ESM, no bundling required! âš¡ï¸ LIGHTNING FAST HMR Hot Module Replacement (HMR) that stays fast regardless of app size. ðŸ› ï¸ RICH FEATURES Out-of-the-box support for TypeScript, JSX, CSS and more. 📦 OPTIMIZED BUILD Pre-configured Rollup build with multi-page and library mode support. 🔩 UNIVERSAL PLUGINS Rollup-superset plugin interface shared between dev and build. 🔑 FULLY TYPED APIS Flexible programmatic APIs with full TypeScript typing.SPONSORS
Become a sponsor on GitHub MIT Licensed | Copyright © 2019-present Evan You & Vite ContributorsDetails
Copyright © 2024 ArchiveBay.com. All rights reserved. Terms of Use | Privacy Policy | DMCA | 2021 | Feedback | Advertising | RSS 2.0