# 暴露 manifest.json

暴露 uni-app 中的 manifest.json,挂载在 window 上。

# 如何使用

安装

pnpm add @plugin-light/webpack-plugin-manifest-expose -D

vue.config.js 中添加如下设置:

const { ManifestExposePlugin } = require('@plugin-light/webpack-plugin-manifest-expose');


module.exports = {
  chainWebpack(config) {
    config.plugin('ManifestExposePlugin')
      .use(new ManifestExposePlugin())
      .tap(args => args);
  }
}

# 参数

export interface IManifestExposeOptions {
  // 默认为 'jsonpScriptSrc',
  jsSrc?: string;

  // 默认为 'cssSrc',
  cssSrc: string;
}

# 更新日志

点此查看

Last Updated: 2025/3/29 16:32:34