Skip to content
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

Docs update for boa_runtime and console documentation #2891

Merged
merged 5 commits into from
May 4, 2023

Conversation

nekevss
Copy link
Member

@nekevss nekevss commented May 2, 2023

Hi all!

This PR is to update the docs to ease any confusion regarding adding console to a project (RE: the discussion on discord). Feel free to let me know if there are any changes you'd like to see or if a more in depth example is needed.

I can't remember if this had been decided yet, but were we publishing boa_runtime? I'm wondering if it would be better to link to boajs.dev's docs for boa_runtime vs. the rustdoc intra-doc link.

It changes the following:

  • Updates the primary example in boa_engine to account for console being moved to boa_runtime
  • Builds out the docs on boa_runtime

@github-actions
Copy link

github-actions bot commented May 2, 2023

Test262 conformance changes

Test result main count PR count difference
Total 94,601 94,601 0
Passed 73,293 73,293 0
Ignored 17,540 17,540 0
Failed 3,768 3,768 0
Panics 0 0 0
Conformance 77.48% 77.48% 0.00%

@codecov
Copy link

codecov bot commented May 2, 2023

Codecov Report

Merging #2891 (caa8236) into main (0636022) will increase coverage by 0.06%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##             main    #2891      +/-   ##
==========================================
+ Coverage   51.23%   51.30%   +0.06%     
==========================================
  Files         427      427              
  Lines       42520    42612      +92     
==========================================
+ Hits        21787    21860      +73     
- Misses      20733    20752      +19     
Impacted Files Coverage Δ
boa_engine/src/lib.rs 78.20% <ø> (ø)

... and 26 files with indirect coverage changes

@nekevss nekevss added the documentation update documentation label May 2, 2023
Copy link
Member

@Razican Razican left a comment

Choose a reason for hiding this comment

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

Looks great to me :) I would just add an extra panic so that we get notified if this fails for whatever reason.

@@ -19,7 +21,12 @@
//! ```
//! use boa_engine::{Context, Source};
//!
//! let js_code = "console.log('Hello World from a JS code string!')";
//! let js_code = r#"
Copy link
Member

Choose a reason for hiding this comment

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

To make sure that we don't miss this again, I would add, in line 45, a panic (hidden with #), so that we catch the error.

Copy link
Member Author

Choose a reason for hiding this comment

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

Updated 😄

@Razican
Copy link
Member

Razican commented May 3, 2023

I can't remember if this had been decided yet, but were we publishing boa_runtime? I'm wondering if it would be better to link to boajs.dev's docs for boa_runtime vs. the rustdoc intra-doc link.

I think the idea is to publish boa_runtime, in case someone wants to use it as-is. It would also allow us to improve it and to add more things to it. I also now that some of our users would like to have a runtime provided by Boa, so we can just point to that if it's in crates.io.

Copy link
Member

@HalidOdat HalidOdat left a comment

Choose a reason for hiding this comment

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

Looks good to me! :)

@Razican Razican added this pull request to the merge queue May 4, 2023
Merged via the queue into main with commit e320c55 May 4, 2023
@bors bors bot deleted the console-documentation branch May 4, 2023 10:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation update documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants