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

Sync Belt / Js doc headers #5361

Merged
merged 69 commits into from
Jun 22, 2022
Merged

Sync Belt / Js doc headers #5361

merged 69 commits into from
Jun 22, 2022

Conversation

ryyppy
Copy link
Member

@ryyppy ryyppy commented Feb 23, 2022

Fixes #4872

This PR syncs back all our written docs from our docs website (see this directory for reference).

Goal is to rescriptify all the inline code examples and later on use the original source as the source of truth for our language api generation.

Lots of manual work, but will be worthwhile.

  • belt.ml
  • belt_Array.mli
  • belt_Float.mli
  • belt_HashMap.mli
  • belt_HashMapInt.mli
  • belt_HashMapString.mli
  • belt_HashSet.mli
  • belt_HashSetInt.mli
  • belt_HashSetString.mli
  • belt_Id.mli
  • belt_Int.mli
  • belt_List.mli
  • belt_Map.mli
  • belt_MapDict.mli
  • belt_MapInt.mli
  • belt_MapString.mli
  • belt_MutableMap.mli
  • belt_MutableMapInt.mli
  • belt_MutableMapString.mli
  • belt_MutableQueue.mli
  • belt_MutableSet.mli
  • belt_MutableSetInt.mli
  • belt_MutableSetString.mli
  • belt_MutableStack.mli
  • belt_Option.mli
  • belt_Range.mli
  • belt_Result.mli
  • belt_Set.cppo.mli (all the cppo files + generated files need to be handled in a different PR. This requires some infrastructural refactor)
  • belt_Set.mli
  • belt_SetDict.mli
  • belt_SetInt.mli
  • belt_SetString.mli
  • belt_SortArray.mli
  • belt_SortArrayInt.mli
  • belt_SortArrayString.mli

Step 1) Syncing up the docs is done.
Step 2) Transform ml files to res

@ryyppy ryyppy force-pushed the sync-belt-doc-headers branch from 71f6b25 to 1728a0c Compare June 6, 2022 10:11
@nkrkv
Copy link
Contributor

nkrkv commented Jun 10, 2022

Made a PR for Option to try things out: #5424

@nkrkv
Copy link
Contributor

nkrkv commented Jun 11, 2022

Also, #5427 for Result

@ryyppy

@whitchapman
Copy link
Contributor

I just opened a PR #5428 for Set -- I will continue with the other Set modules. I'll probably just push to this same PR unless someone gives me some feedback to do otherwise. cc @ryyppy

@whitchapman
Copy link
Contributor

whitchapman commented Jun 11, 2022

I just opened a PR #5428 for Set -- I will continue with the other Set modules. I'll probably just push to this same PR unless someone gives me some feedback to do otherwise. cc @ryyppy

I also included SetInt, SetString, SetDict, MutableSetInt, and MutableSetString in the same PR #5428.

@Minnozz
Copy link
Contributor

Minnozz commented Jun 11, 2022

I'll start with belt_Map.mli in #5429.
Edit: I'll continue with belt_Map{Dict,Int,String}.mli and possibly belt_MutableMap*.mli afterwards.

@nkrkv
Copy link
Contributor

nkrkv commented Jun 16, 2022

Created #5442 for js_option.ml

@nkrkv
Copy link
Contributor

nkrkv commented Jun 16, 2022

Created #5443 for js_re.ml

@ryyppy ryyppy changed the title Sync belt doc headers Sync Belt / Js doc headers Jun 21, 2022
@ryyppy
Copy link
Member Author

ryyppy commented Jun 22, 2022

Alright, things that are now done:

  • Sync up Belt docs ✅
  • Sync up Js docs ✅

Now the next step is to convert all of those files from mli / ml to res (will probably do that in a separate PR).

Follow-up task will be handling the issue with cppo files as described in #5458.

@ryyppy ryyppy marked this pull request as ready for review June 22, 2022 07:08
@cristianoc
Copy link
Collaborator

Wonderful!

@cristianoc cristianoc merged commit c3fcc43 into master Jun 22, 2022
@ryyppy ryyppy deleted the sync-belt-doc-headers branch June 22, 2022 07:22
mununki pushed a commit to mununki/rescript-compiler that referenced this pull request Jul 15, 2022
* Sync doc headers for belt.ml

* Sync doc headers for belt_Array.mli

* Update belt_Float.mli doc headers

* Sync docs for belt_HashMap.mli

* Sync docs for belt_HashMapInt.mli

* Sync docs for belt_HashMapString.mli

* Sync belt_HashSet.mli

* Update belt_HashMapInt

* Sync belt_HashSetString.mli

* Sync docs for belt_Int.mli

* Sync docs for belt_List.mli

* Sync docs for belt_Option.mli

* Adapt docs in belt_Option.mli for parts missing in rescript-lang.org MDX

* Sync docs for belt_Result.mli

* Sync docs for belt_Set.mli

* Sync docs for belt_SetInt.mli

* Sync docs for belt_SetString.mli

* Sync docs for belt_SetDict.mli

* Sync docs for belt_MutableSetInt.mli

* Sync docs for belt_MutableSetString.mli

* Sync all the docstring texts from sort-array.mdx

* Remove duplication of type definitions

* Sync all the docstring texts from sort-array-int.mdx

* Sync docs for belt_Map.mli

* Sync docs for belt_MapInt.mli

* Sync docs for belt_MapString.mli

* Sync docs for belt_MutableMap.mli

* Sync docs for belt_MutableMapInt.mli

* Sync docs for belt_MutableMapString.mli

* Remove duplicate type signatures

* Sync all the docstring texts from sort-array-string.mdx

* Sync docs for belt_MutableSet.mli

* Sync docs for belt_Range.mli

* Sync docs for belt_MutableQueue.mli

* Sync docs for belt_MutableStack.mli

* Sync docs for Js.ml

* Sync docs for js_array.ml

* Sync docs for js_array2.ml

* Sync docs for js_date.ml

* Sync docs for js_dict.mli

* Sync docs for js_exn.mli

* Sync docs for js_float.ml

* Sync docs for js_math.ml

* Sync docs for js_option.ml

* Sync docs of js_global.ml

* Sync docs for js_int.ml

* Sync docs for js_re.ml

* Sync docs for js_json.mli

* Sync docs for js_null.mli

* Sync docs for js_null_undefined

* Sync docs for js_obj.ml

* Sync docs for js_promise.ml

* Sync docs for js_string.ml

* Fix misplaced doc in js_array2

* Sync docs for js_string2.ml

* Update docs for js_types.mli

* Sync docs for js_undefined.mli

* Sync docs for js_vector.mli

Co-authored-by: Patrick Ecker <ryyppy@users.noreply.github.com>
Co-authored-by: Victor Nakoryakov <nail.xx@gmail.com>
Co-authored-by: Whit Chapman <whit.chapman@gmail.com>
Co-authored-by: jihchi <achi@987.tw>
Co-authored-by: Bart Schuurmans <bart@minnozz.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Convert belt comment doc examples to rescript syntax
7 participants