swup / docs

Official swup documentation 📘
https://swup.js.org/getting-started
12 stars 35 forks source link

Update plugin docs #63

Closed daun closed 2 years ago

daun commented 2 years ago
hirasso commented 2 years ago

Looks great!!

hirasso commented 2 years ago

I've just tested it locally and the process already is pretty painless. Keeping the front matter automatically would still be an improvement, I think.

daun commented 2 years ago

Added your proposed changes. Keeping the frontmatter would indeed be great, but would be much more complicated then the 'dumb' version used here. Not too motivated to keep exploring here 🤡

hirasso commented 2 years ago

I have done some refactoring on the script, see above. I hope it's ok that I'm chiming in with own commits to the PR :)

...I noticed that http.get doesn't error if the response.statusCode is 404, that's why I added the check for it. Otherwise, the script would create a file for the non-existing plugin with contents of "404: Not Found".

daun commented 2 years ago

Perfect! Feel free to review and merge.