Skip to content

transformedAssetTypes is ignored #1339

Closed
@renestalder

Description

@renestalder

I am using Pattern Lab Node v5.15.0 on Linux, with Node v16, using a Twig Edition.

Expected Behavior

When using a preprocessor like PostCSS to process CSS files, you want to deactivate the copy task for CSS. To do this, based on the manual, I would set following property in my pattern lab configuration:

{
  "transformedAssetTypes": ["css", "js"]
}

Now building pattern lab, the public css folder set in paths.public.css should not contain any CSS files.

Actual Behavior

transformedAssetTypes seems to ignore the type "css". It copies all the CSS files as configured in paths.source.css to paths.public.css.

As the preprocessor might be faster in compliling, Pattern Lab is also gonna overwrite any previously compiled CSS.

Actually, after testing further, it seems that setting is not applied any file type. I tested it with .scss as file type by setting transformedAssetTypes to ["scss"] and file is still being copied despite the setting.

Steps to Reproduce
  1. Configure paths for CSS in paths.source.css and paths.public.css.
  2. Add a CSS file to the source path
  3. Set the transformedAssetTypes to ["css"].
  4. Run patternlab build --config ./patternlab-config.json

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