Skip to content

Invalid top-level expression #29

@FilmKnurd

Description

@FilmKnurd

This is not a problem with this plugin, but I'm posting this in case someone else runs into this issue.

Compilation failed for me with

Metalsmith · [metalsmith-sass] Error: invalid top-level expression -> /Users/veritas/www/hannahsstudio.com/src/styles/style.scss:1:1

I thought the issue was with the SASS file or with this plugin. I finally looked at the plugin source code and saw that the data option was set to the file contents. It turns out all my files were being processed by the layouts plugin, so the data option had a bunch of HTML templating inside it. I just had to set the patterns option in the layouts plugin to only process markdown files.

This might be a good note to put in the documentation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions