Skip to content

Conversation

@sigma-andex
Copy link
Contributor

No description provided.

Copy link
Contributor

@JordanMartinez JordanMartinez left a comment

Choose a reason for hiding this comment

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

Overall looks good.

Should we create a tag in this repo of its state before any ES modules work gets merged and then link to that for everyone on pre-0.15.x?

guides/FFI.md Outdated

- The name of the foreign module must be the same as its companion PureScript module, with its extension changed to `.js`. This associates the foreign module with the PureScript module.
- All exports must be of the form `exports.name = value;`, specified at the top level.
- All exports must be of the form `export const name = value;`, specified at the top level.
Copy link
Contributor

Choose a reason for hiding this comment

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

This is only true for values, not necessarily functions (as the example below breaks this rule).

Comment on lines 334 to 344
### Compiling CommonJS Modules

Spago can also be used to generate CommonJS modules from PureScript code. This can be useful when using NodeJS, or just when developing a larger project which uses CommonJS modules to break code into smaller components.

To build CommonJS modules, use the `spago build` command:

$ spago build
...
Build succeeded.

The generated modules will be placed in the `output` directory by default. Each PureScript module will be compiled to its own CommonJS module, in its own subdirectory.
Copy link
Contributor

Choose a reason for hiding this comment

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

I feel like this is still important to say but for ES modules now.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ok will add it again with ES modules then

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 have added it again and updated to es modules. However I think this paragraph needs a bigger rewrite, it doesn't make much sense anymore imho.

@sigma-andex
Copy link
Contributor Author

Overall looks good.

Should we create a tag in this repo of its state before any ES modules work gets merged and then link to that for everyone on pre-0.15.x?

Sounds good

@JordanMartinez
Copy link
Contributor

Perhaps we shouldn't merge this until we're getting closer to the v0.15.0 release?

Regardless, I've made the pre-0.15.0-era tag.

@sigma-andex
Copy link
Contributor Author

@JordanMartinez should we merge this already?

@JordanMartinez
Copy link
Contributor

I think we'll do so immediately after the 0.15.0 release is made. See also #392

@JordanMartinez
Copy link
Contributor

Hmm... Then again, this is the first draft, meaning there are other changes we might want to make. And I already have the 0.14-era tag made.

@sigma-andex
Copy link
Contributor Author

@JordanMartinez should we merge this now?

@JordanMartinez
Copy link
Contributor

@sigma-andex I don't think so. My main reasons against merging this now is because 0.15.0 isn't out yet. If it gets delayed by some other issue, then this repo's documentation will be incorrect, and it's one of the first things to which we direct new users.

On the other hand, we don't have a branch where we can iterate on the 0.15.0 updates to this repo. So, I think instead a new branch should be created 0.15.0-updates into which we merge this and #392. Then, we can iterate on that branch and then merge that branch into master once 0.15.0 comes out.

@JordanMartinez JordanMartinez changed the base branch from master to updates-for-0.15 April 27, 2022 10:08
@JordanMartinez JordanMartinez merged commit 65cacd6 into purescript:updates-for-0.15 Apr 27, 2022
@JordanMartinez JordanMartinez deleted the update-documentation-for-v0.15 branch April 27, 2022 10:09
JordanMartinez added a commit that referenced this pull request Apr 29, 2022
* First draft of documentation update for v0.15 (#421)

* First draft of documentation update for v0.15

* Describe ambiguous matches in instance chains (#392)

* Update tool versions

* Update parsing library changelog

* Update 0.15 guides to account for `Stream.write` breaking change

Co-authored-by: sigma-andex <77549848+sigma-andex@users.noreply.github.com>
Co-authored-by: Ryan Hendrickson <ryan.hendrickson@alum.mit.edu>
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