Skip to content

Improve docs #52

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

Merged
merged 6 commits into from
Dec 11, 2015
Merged

Improve docs #52

merged 6 commits into from
Dec 11, 2015

Conversation

hdgarrood
Copy link
Contributor

See the commit messages for a description of the changes.

- Fix deprecated syntax [a] for Array a
- Add a missing full stop
It confuses `psc-docs` and ends up stripping documentation. We should
fix this in the compiler eventually.
@hdgarrood
Copy link
Contributor Author

I thought it would be good to add details of the instances because a) Array is a native type so instances aren't listed, and b) this is probably confusing beginners: "Why is there no function for concatenating arrays in Data.Array?"

@@ -1,7 +1,8 @@
language: node_js
sudo: false
node_js:
- 0.10
- 4.2
- 5.2
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it worth just specifying 4 and 5 here so the latest point release of each is used?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wasn't aware you could do that! Definitely sounds sensible. Will do.

at least one `true`.
* `Traversable`, which provides the PureScript version of a for-loop,
allowing you to iterate over an array and accumulate effects.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, had another thought. Perhaps we could make these link to the appropriate classes rather than having to include types, etc? Or maybe both if you think it's useful to include this info here as well.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That [edit: linking] would be nice, but we'd have to choose a specific version of prelude/foldable-traversable to link to, which might cause problems if things change. These particular classes probably won't change that much, but other stuff in those packages might.

I had beginners in mind in particular with this paragraph, or rather, people who aren't yet familiar with all of these type classes. For example, I've encountered people more than once in IRC who were confused about why Data.Array doesn't have a function analogous to JS' Array.prototype.concat. So that's why I included this info here.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, ok. I kinda assumed you could leave the version out of the URL and it would redirect to the latest, the way it does for the package route. But that wouldn't help anyway if things moved around.

Makes sense.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think giving people a way of linking to a particular type in the documentation could be really nice, but I haven't quite figured out how to do it well just yet.

garyb added a commit that referenced this pull request Dec 11, 2015
@garyb garyb merged commit 8b767db into purescript:master Dec 11, 2015
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 this pull request may close these issues.

2 participants