Skip to content

Add recommended tooling for PureScript applications #274

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
thomashoneyman opened this issue Sep 26, 2019 · 10 comments · Fixed by #347
Closed

Add recommended tooling for PureScript applications #274

thomashoneyman opened this issue Sep 26, 2019 · 10 comments · Fixed by #347

Comments

@thomashoneyman
Copy link
Member

I recently posted a short Discourse thread, Recommended Tooling for PureScript Applications in 2019. It clears up the tools that I recommend when new folks ask what they're supposed to use to build their PureScript web applications. It's received a warm response in Slack and on Discourse.

It's hard enough getting started with a new language and it helps beginners to know what they can at least install to get a new single-page application going. At minimum, I'm glad to see things moving towards recommending Spago, but it would also be useful to recommend Yarn for npm packages / script running and Parcel or Webpack for bundling. I think these are the three categories of tool that are necessary to build a typical PureScript app which involves any JavaScript libraries.

Note that this would only be about single-page applications; PureScript is used in other contexts, too, and in those contexts Yarn and Parcel don't necessarily make sense to recommend.

To reiterate: I suggest updating the documentation repository and/or purescript.org to recommend Yarn, Spago, and Parcel (or Webpack) for building web applications with PureScript, while also noting that other tools exist and are perfectly usable.

@thomashoneyman
Copy link
Member Author

Alternately we could just crib parts of the post itself into the documentation, but the post is probably too opinionated and touches on too many tools for that.

@hdgarrood
Copy link
Collaborator

Why Yarn over npm? npm does more or less everything I want it to, and it comes with node.js, which is a big plus. I’d prefer to let people discover and use Yarn themselves if they aren’t happy with npm, personally.

@thomashoneyman
Copy link
Member Author

Now that I'm looking around it looks like npm has improved dramatically since the old days of non-deterministic node_modules directories and slow installation times. With that in mind I don't have strong arguments for one or the other, and I understand that npm already coming with the node installation is a plus.

I'm not an npm user myself these days so I'm not up-to-date on arguments for or against and I'll have to defer to others more knowledgeable than I on the topic.

There was also Connor Prussin’s comment on npx in the tooling thread, though it was directed at yarn + npx.

With all this in mind, I'd also be happy with npm + spago + parcel/webpack.

@hdgarrood
Copy link
Collaborator

The main problem (which I probably should have led with, sorry) is that I don't think it would be appropriate to privilege any particular library for frontend apps (halogen, react-basic, concur, etc), and I'm not sure there's a sensible way of putting together a guide like the one you have in mind without doing that. What do you think?

@thomashoneyman
Copy link
Member Author

I was only thinking of recommending tools which are common across frontend projects, like the three mentioned so far (npm, spago, parcel) and perhaps tools like purty and zephyr where there's only one choice in the category.

It's possible to include more of the guide, like the other tools or the project setup walkthrough, but that seemed too opinionated &/or likely to get out of date. This isn't meant as an update to documentation which is a brand-new guide, but rather just a small "You're getting started; these are the essential tools you can use for frontend projects, until you are informed enough to search out alternatives for your project."

@hdgarrood
Copy link
Collaborator

@prescientmoon
Copy link

I personally really like using pnpm over both npm and yarn so I dont think having any of those be the recommended one a good idea since everyone has his own opinions on package managers

@garyb
Copy link
Member

garyb commented Mar 6, 2020

I think if someone has an existing preference then they'll be aware that they can just use that instead. That part is more intended for people who don't have anything set up yet.

@milesfrain
Copy link
Contributor

#343 Wants to link to the 2020 thread, so this seems like content that users would find helpful to be discoverable in this docs repo.

@thomashoneyman
Copy link
Member Author

All tooling in the 2020 version of recommended tools for PureScript are library-agnostic (no preferred framework like Halogen), and there’s no setup guide, which makes it more palatable to move directly into this documentation (which I’m on board with)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants