Skip to content

Using sass (dart-sass) with css2json-loader acts weird and crashes the app #5257

Open
@bundyo

Description

@bundyo

Environment
Provide version numbers for the following components (information can be retrieved by running tns info in your project folder or by inspecting the package.json of the project):

  • CLI: 6.4.x (probably happens on older)
  • Cross-platform modules: 6.4.x (same)
  • Android Runtime: 6.4.x
  • iOS Runtime: 6.4.x

Describe the bug
An app with SCSS that is handled with sass implementation (dart-sass) and then served through css2json-loader produces code in the form of "undefinedundefined" inside bundle.js, just after the css2json produced code and app crashes on startup. Removing the css2json-loader and using css-loader works normal. Changing Webpack to 4.40.x produces several pages filled with "undefinedundefinedundefined...".

To Reproduce
Use the provided project and try to run it.

Expected behavior
To run.

Sample project
css2json-loader_sass_issue.zip

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