Initial feedback on plugin authoring
- Dominant language
- F#
- Stars
- 145
- Forks
- 10
- Avg merge
- 3d 13h
- Merged PRs (30d)
- 1
Description
Hi, I'm the guy that pinged you over on mastodon :)
First, some unrelated feedback on perla:
After running `dotnet perla new MyProject` it gives a selection of templates: Awesome!
Then it shows hints about quick access commands:
>Perla: This template has quick access commands:
Perla: perla new -t solid
Perla: Next time you can run perla new -id perla.templates.solid.js
Also cool,
Finally it says successful. I think it would be nice if it could also show a hint about how to start the newly created template. Something like:
> Perla: To see your new website, run `perla serve` and open your browser
or similar.
---
Now for the plugin feedback. I understand everything is still very early in development, and you've been spending your time on more important things. That being said, from the initial look at the [markdown plugin](https://github.com/AngelMunoz/Perla/blob/dev/docs/.perla/plugins/markdown.fsx) it seems that the primary purpose of perla plugins is to allow loading file types not natively supported by esbuild. Is this a correct assumption, or were you also envisioning other plugins that transform/extract data from existing files as they travel through the pipeline? Or is this better suited for esbuild plugins (which would require node again -.- )
Context: I want to write a plugin to allow usage of [TailwindCSS via their standalone executable](https://tailwindcss.com/blog/standalone-cli). This would require looking at existing files, and then creating a new/replace an existing css file in the output.
As far as the debugging experience goes, maybe I haven't poked around enough with it, but it would be nice to have access to the perla context of "input" directory and "output" directory, and being able to access the vfs to see what files exist there.
Lastly, add some kind of hint that `perla-esbuild-plugin` is a required plugin when setting the plugins array option
Thanks a bunch
Contributor guide
Research direction
Start with docs/.perla/plugins/markdown.fsx and the plugin configuration mentioned in the issue, then inspect how perla-esbuild-plugin is referenced. The request covers plugin semantics, context and VFS access, Tailwind integration, and CLI hints, so it first needs a maintainer decision on scope. Done would require an agreed design and corresponding documentation or implementation tasks.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- fsharp, tailwindcss
- Domain
- cli, tooling
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100