Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace gulp usage with abp install-libs command in the documents #9872

Merged
merged 5 commits into from
Aug 23, 2021
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ namespace SignalRTieredDemo.Web
{
````

Also, we need to add [@abp/signalr](https://www.npmjs.com/package/@abp/signalr) npm package to package.json in ***.Web** project, then run **yarn** and **gulp** commands.
Also, we need to add [@abp/signalr](https://www.npmjs.com/package/@abp/signalr) npm package to package.json in ***.Web** project, then run **abp install-libs** command.

`````json
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,9 @@ module.exports = {

Open your `DevExtremeSample.Web` project folder with a command line and run the `gulp` command. This command will copy the needed library files into the ``/wwwroot/libs/devextreme/` folder.
realLiangshiwei marked this conversation as resolved.
Show resolved Hide resolved

![gulp](gulp.png)
````bash
abp install-libs
````

You can see `devextreme` folder inside the `wwwroot/libs`:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ You can install the latest version (3.1.13 will be old)

#### 3- Add resource Mapping

We added SignalR to the `package.json` but it comes into your `node_modules` folder. We need to copy the related files to `wwwroot/libs` folder. To do this copy the content of the following file to your `abp.resourcemappings.js` file. It's in your root directory of Web folder. After you do this, go to your web directory and run `gulp` command. By doing this, it'll copy the related files into your `wwwroot/libs` folder.
We added SignalR to the `package.json` but it comes into your `node_modules` folder. We need to copy the related files to `wwwroot/libs` folder. To do this copy the content of the following file to your `abp.resourcemappings.js` file. It's in your root directory of Web folder. After you do this, go to your web directory and run `abp install-libs` command. By doing this, it'll copy the related files into your `wwwroot/libs` folder.

[abp.resourcemappings.js](https://gist.github.com/ebicoglu/f7dc22cca2d353f8bf7f68a03e3395b8#file-abp-resourcemapping-js)

Expand Down
5 changes: 3 additions & 2 deletions docs/en/Modules/Virtual-File-Explorer.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,9 @@ Or you can also manually install nuget package to `Acme.MyProject.Web` project:

Then open the command line terminal in the `Acme.MyProject.Web` project folder and run the following command:

1. `yarn`
2. `gulp`
````bash
abp install-libs
````

That's all,Now run the application and Navigate to `/VirtualFileExplorer`. You will see virtual file explorer page:

Expand Down
4 changes: 2 additions & 2 deletions docs/en/SignalR-Integration.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,10 +70,10 @@ This will add the `@abp/signalr` to the dependencies in the `package.json` of yo
}
````

Run the `gulp` in the root folder of your web project:
Run the following [ABP CLI](CLI.md) command in the root folder of your web project:

````bash
gulp
abp install-libs
````

This will copy the SignalR JavaScript files into your project:
Expand Down
2 changes: 1 addition & 1 deletion docs/en/UI/AspNetCore/Basic-Theme.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ The Basic Theme has RTL (Right-to-Left language) support.
* Install the [Volo.Abp.AspNetCore.Mvc.UI.Theme.Basic](https://www.nuget.org/packages/Volo.Abp.AspNetCore.Mvc.UI.Theme.Basic) NuGet package to your web project.
* Add `AbpAspNetCoreMvcUiBasicThemeModule` into the `[DependsOn(...)]` attribute for your [module class](../../Module-Development-Basics.md) in the web project.
* Install the [@abp/aspnetcore.mvc.ui.theme.basic](https://www.npmjs.com/package/@abp/aspnetcore.mvc.ui.theme.basic) NPM package to your web project (e.g. `npm install @abp/aspnetcore.mvc.ui.theme.basic` or `yarn add @abp/aspnetcore.mvc.ui.theme.basic`).
* Run `gulp` command in a command line terminal in the web project's folder.
* Run `abp install-libs` command in a command line terminal in the web project's folder.

## Layouts

Expand Down
14 changes: 6 additions & 8 deletions docs/en/UI/AspNetCore/Client-Side-Package-Management.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ To solve the versioning problem, we created a **standard set of packages** those
The benefit of a **standard package** is:

* It depends on a **standard version** of a package. Depending on this package is **safe** because all modules depend on the same version.
* It contains the gulp task to copy library resources (js, css, img... files) from the **node_modules** folder to **wwwroot/libs** folder. See the *Mapping The Library Resources* section for more.
* It contains the mappings copy library resources (js, css, img... files) from the **node_modules** folder to **wwwroot/libs** folder. See the *Mapping The Library Resources* section for more.

Depending on a standard package is easy. Just add it to your **package.json** file like you normally do. Example:

Expand Down Expand Up @@ -61,7 +61,7 @@ Using NPM packages and NPM/Yarn tool is the de facto standard for client side li

Next challenge is copying needed resources (js, css, img... files) from the `node_modules` into a folder inside the **wwwroot** folder to make it accessible to the clients/browsers.

ABP defines a [Gulp](https://gulpjs.com/) based task to **copy resources** from **node_modules** to **wwwroot/libs** folder. Each **standard package** (see the *@ABP NPM Packages* section) defines the mapping for its own files. So, most of the time, you only configure dependencies.
ABP CLI's `abp install-libs` command **copies resources** from **node_modules** to **wwwroot/libs** folder. Each **standard package** (see the *@ABP NPM Packages* section) defines the mapping for its own files. So, most of the time, you only configure dependencies.

The **startup templates** are already configured to work all these out of the box. This section will explain the configuration options.

Expand Down Expand Up @@ -100,17 +100,15 @@ mappings: {
}
````

#### Using The Gulp
#### install-libs Command

Once you properly configure the `abp.resourcemapping.js` file, you can run the gulp command from the command line:
Once you properly configure the `abp.resourcemapping.js` file, you can run the following ABP CLI command from the command line:

````
gulp
abp install-libs
````

When you run the `gulp`, all packages will copy their own resources into the **wwwroot/libs** folder. Running `yarn & gulp` is only necessary if you make a change in your dependencies in the **package.json** file.

> When you run the Gulp command, dependencies of the application are resolved using the package.json file. The Gulp task automatically discovers and maps all resources from all dependencies (recursively).
When you run this command, all packages will copy their own resources into the **wwwroot/libs** folder. Running `abp install-libs` is only necessary if you make a change in your dependencies in the **package.json** file.

#### See Also

Expand Down