Skip to content
This repository was archived by the owner on Aug 7, 2021. It is now read-only.
This repository was archived by the owner on Aug 7, 2021. It is now read-only.

Support for LESS CSS #967

Open
Open
@DimitarTachev

Description

@DimitarTachev

Is your feature request related to a problem? Please describe.
If you try to use app.less instead of app.css, you will get You may need an appropriate loader to handle this file type. webpack compilation error.

Describe the solution you'd like
We have to provide less loader by default (or by an additional plugin).

Workaround

  1. npm i less --save-dev
  2. npm i less-loader --save-dev
  3. Register the loader in your webpack.config:
{
  test: /\.less$/,
  use: [
    { loader: "css-loader", options: { url: false } },
    less-loader"
  ]
},
  1. Add the less extention in the resolve section:
    extensions: [".js", ".scss", ".less", ".css"],
  2. Add the less extension in the nativescript-dev-webpack/style-hot-loader regex:
    test: /\.(css|scss|less)$/,

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions