Abp: gulp vs libman

Created on 17 Sep 2019  路  2Comments  路  Source: abpframework/abp

What is the point of having the custom gulp task when we can use libman and it is easier?

Thank you

question

Most helpful comment

Thanks @Xeevis for your great explanation. I wouldn't write better :)

All 2 comments

Libman is a simple file downloader. When developing single website where you know which exact resources you want to have in your wwwroot folder, it may be sufficient in most scenarios, but it will fall short in modular environments like ABP. Gulp helps with dependencies, if you create ABP module and want to use TUI editor. You'll just add @abp/tui-editor in your project's package.json file. Yarn will pull the entire dependency tree to a node_modules folder.

@abp/codemirror
> @abp/core
> codemirror
@abp/highlight.js
> @abp/core
@abp/jquery
> @abp/core
> jquery
@abp/markdown-it
> @abp/core
> markdown-it

Each package in the @abp namespace then has extra manifest file abp.resourcemapping.js that tells gulp which files to copy for each module's BundleContributor to pick up. While manifest files are similar between the two, libman works only from root of your web project as it can't scope higher than it's working directory. This means it's impossible to let modules resolve their own dependencies with it, you'd have to maintain all files of all modules and their dependencies in your own libman.json manually.

Thanks @Xeevis for your great explanation. I wouldn't write better :)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

hikalkan picture hikalkan  路  3Comments

ChangYinShung picture ChangYinShung  路  3Comments

SmallShrimp picture SmallShrimp  路  3Comments

mehdihadeli picture mehdihadeli  路  3Comments

Trojaner picture Trojaner  路  3Comments