npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

webpack-ng-dll-plugin

v2.3.1

Published

ng远程加载插件库

Downloads

79

Readme

webpack-ng-dll-plugin

  • 一个 ng 远程加载插件库

ng-named

  • 主要用来在主项目中导出相关命名(组件,模块,服务,指令,管道及正常的 export 等)
  • 子项目正常引入主项目的资源,在构建时会自动的替换为引入函数
  • 远程子项目使用需要建立虚拟子项目当做桩,相关路径符合定义的context+导出的资源文件即可

主项目使用

  • NgNamedExportPlugin 类似 dll,但是实际上是跑在主项目上的 dll,也就是两种的合体,可以在主项目内部被正常使用的同时,暴露给子项目使用
  • 如果模块上有组件/指令/管道等可能被摇树掉的东西,那么就需要同样在出口声明导出

子项目使用

  • NgNamedImportCheckPlugin 用于子项目应用的依赖检查,比如正常引入一个模块,实际上要使用这个模块内的一个组件,那么可能这个组件就忘记被导出,需要在出口文件导出

    如果检查到依赖未导出,默认情况下,会警告提示,不会中断项目

remote

  • 将子项目链接到主项目,使得主项目能正确的找到相关子项目

主项目使用

  • RemoteModuleStartupMainTemplatePlugin 用于加载远程项目,不过是单文件的加载
  • RemoteModuleManifestStartupMainTemplatePlugin 用于加载远程项目,支持一个清单,进行多个 js 文件,多个 css 文件的加载

子项目使用

  • RemoteModuleManifestStartupMainTemplatePlugin 使用类似runtimeJsonp方式加载到主项目中

dll

  • 提取主项的依赖,并且通过DllReferencePlugin使主项目,子项目使用相同依赖

主项目

  • NgDllPlugin 参考webpackDllPlugin 生成 dll
  • DllReferencePlugin 引用 dll

子项目

  • DllReferencePlugin 引用 dll