• webpack
  • 入门
    • 动机
    • webpack 是什么
    • 安装
    • 用法
    • 引用模块
    • Vendor Modules
    • 使用加载器
    • 使用插件
    • 开发工具
    • 疑难解答
  • 教程及示例
    • 入门
    • 教程列表
    • 示例
  • 指南
    • CommonJs
    • AMD
    • 从 browserify 切换到 webpack
    • 代码分离
    • 样式
    • 优化
    • 持久缓存
    • 编写加载器
    • 多入口
    • 库和第三方代码
    • Shimming modules
    • 测试
    • 构建的性能
    • 用 webpack 来做模块热更新
    • 对比
  • 搭配工具
    • grunt
    • gulp
    • bower
    • karma
  • 资源列表
    • 加载器惯例
    • 加载器列表
    • 插件列表
    • 指南列表
  • API
    • 配置
    • 命令行
    • Node.js API
    • 模块中的 API
    • 加载器
    • 插件
    • 上下文环境
    • 解析
    • 模块热更新
    • 开发工具
      • webpack 开发服务器
      • webpack 开发服务器中间件
  • 开发
    • 变更日志
    • 路线图
    • 点子
    • 贡献
  • Published with GitBook

示例

示例

simple examples

Basic usage

CommonsJs

Code Splitting

  • Code Splitting
  • Code Splitting with the bundle-loader

multiple entry points

multiple entry points

module styles

  • labeled modules
  • CommonsJs, AMD and labeled modules mixed
  • Component modules

library and externals

  • library option with multiple entry points and UMD
  • using stuff from other scripts

loaders

  • using loaders
  • using coffee-script

context

  • dynamic require
  • dynamic require with a single chunk
  • dynamic require with a single chunk (AMD)
  • TODO: dynamic require with a chunk per module

i18n

  • using the i18n plugin

advanced examples

advanced CommonsJs

  • require.resolve

advanced Code Splitting

  • aggressive merging of chunks
  • moving modules between chunks
  • routing with multiple entry points and Code Splitting

multi compiler

  • using multiple configurations

deduplication

  • using the deduplication plugin
  • deduplication with Code Splitting

commons chunk plugin

  • using the a commons chunk

stylesheet

  • extracting a stylesheet for the css modules
  • +Code Splitting
  • + commons chunk

WebWorker

  • using the webworker-loader

named chunks

  • merging chunks with naming

results matching ""

    No results matching ""