Using OneSDK in Angular

To use OneSDK with Angular, you need to configure your build tool to process SVG, CSS and path alias.

If you use webpack, please use https://webpack.js.org/loaders/ to install required loaders and configure the corresponding settings.

Webpack's official documentation provides sufficient coverage for these scenarios.

For your convenience, the relevant links are provided below:

If you use webpack v5:

If you use webpack v4 or below:


Adding CSS Loader and Asset Modules using Custom-Webpack in an Angular Project

  1. Install Custom-Webpack Package:

    • Run the following command in your terminal:
      npm install @angular-builders/custom-webpack
      
  2. Modify tsconfig.json:

    • Open your tsconfig.json file.
    • Add the following line to the compiler options section:
      "skipLibCheck": true
      
  3. Utilize Custom-Webpack:
    Ensure your project is configured to use custom-webpack for modifying Angular's webpack configuration. Follow the custom-webpack documentation for detailed steps if needed.