DEV Community

Discussion on: Simple SCSS with 11ty

Collapse
 
aldo_ea profile image
Aldo

Hi @adamkdean! Thank you very much for this post.

I'm new with 11ty and I can't find more info about this part:

"As I understand it, by having a file with a .11ty.js suffix, you're able to introduce some functionality into an endpoint, the path of which you can define in the permalink field of the data() method in the class you return. You can then define the output of that endpoint by returning a string from the render() methods of that class."

Could you tell me where I could find more info about that?
Thank you in advance!

Collapse
 
patricknelson profile image
Patrick Nelson

I was confused about this too, check out: 11ty.dev/docs/languages/javascript/

Basically: It's 11ty's way of finding a way to treat a JavaScript file the way it would a template like *.njk, *.md or whatever. Since they're JS, they just need to follow a certain structure so that they export some kind of content. In this case, CSS. 😄