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

[WIP] React 18 support #1068

Draft
wants to merge 90 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
90 commits
Select commit Hold shift + click to select a range
4ad0c65
Upgrade to React 18.0.0
japgolly May 4, 2022
3ecdcb6
Upgrade Scalajs to 1.10.0
japgolly May 4, 2022
0bde31a
Upgrade microlibs to 4.1.0
japgolly May 4, 2022
b05183a
Upgrade Scalafix and co
japgolly May 4, 2022
49eed7d
Add a doc symlink for DX
japgolly May 11, 2022
4b813a7
Add setting required to make React 18.0.0 work from sbt
japgolly May 11, 2022
7c8203e
Upgrade `ReactDOM` for React 18
japgolly May 11, 2022
ccd2b8a
Use `scalajs-java-securerandom` in tests
japgolly May 11, 2022
90f9fd4
Upgrade Scala3 to 3.1.2
japgolly May 11, 2022
29ef55f
Add a new typeclass `Renderable`
japgolly May 11, 2022
a62a566
Get React 18 working with `jsDependencies`
japgolly May 11, 2022
6753226
Upgrade to React 18.1.0
japgolly May 11, 2022
d55efcd
Fix the output of assertOuterHTML when untitled
japgolly May 11, 2022
e855a81
Add `assertInnerHTML`
japgolly May 11, 2022
a03b5c5
Add LegacyReactTestUtils
japgolly May 20, 2022
d49f00f
Use LegacyReactTestUtils from tests for now
japgolly May 20, 2022
85d1360
Progress tests a little
japgolly May 20, 2022
d764811
Fix new container types
japgolly May 20, 2022
b34989f
Update ReactTestUtils for React 18
japgolly May 27, 2022
486e9e4
Deprecate Profiler interactions & fix last test
japgolly May 27, 2022
769e536
i'm tired
japgolly May 27, 2022
148df90
Fix Scala 3
japgolly May 27, 2022
93d402d
Fix downstream tests
japgolly May 27, 2022
39c55e1
Fix downstream tests & semver
japgolly May 30, 2022
163c69c
Fix logic in `Simulate.wrap`
japgolly May 30, 2022
11899fd
react-dom and react-dom/client are separate
rpiaggio Jan 27, 2024
8a6aa1f
adjustments to make tests run
rpiaggio Jan 28, 2024
804ed13
bump react to 18.2.0
rpiaggio Jan 29, 2024
9fbd1cc
release documentation
rpiaggio Jan 29, 2024
1c9b18b
upgrade fast-text-encoding version
rpiaggio Jan 29, 2024
b03fb2e
fix fast-text-encoding dependency
rpiaggio Jan 29, 2024
0acfb50
release notes
rpiaggio Feb 2, 2024
be6dced
Add useId hook
hugo-vrijswijk Feb 13, 2024
566b1f8
Add useTransition hook
hugo-vrijswijk Feb 13, 2024
fb144a7
change future release to 3.0.0
rpiaggio Mar 6, 2024
a11694f
displayName in functional components
rpiaggio Mar 1, 2024
72408b1
disable mima test
rpiaggio Mar 5, 2024
8091d0a
add release notes
rpiaggio Mar 5, 2024
814e16e
Scala 3 compatible code
rpiaggio Mar 5, 2024
f180e39
add documentation
rpiaggio Mar 6, 2024
1d7a91e
somewhat better default display names
rpiaggio Jul 11, 2024
62712af
fix test
rpiaggio Jul 11, 2024
68dba62
Wrap router actions in startTransition
hugo-vrijswijk Jul 24, 2024
a1aa1bb
Merge pull request #1096 from hugo-vrijswijk/router-transition
rpiaggio Jul 25, 2024
bf0f60c
add flake
rpiaggio Dec 10, 2024
080b937
first steps toward extensible parser for router
rpiaggio Dec 10, 2024
0865043
flexible route model
rpiaggio Dec 11, 2024
2c028fc
update versions, dial back jdk
rpiaggio Dec 11, 2024
cf15d1f
even more flexible route
rpiaggio Dec 11, 2024
83ad0d1
bump semanticdb
rpiaggio Dec 12, 2024
c6fad3b
Merge pull request #1098 from japgolly/custom-routes
rpiaggio Dec 12, 2024
52c00f9
update changelog
rpiaggio Dec 12, 2024
81ed6a9
bump sbt-ci-release
rpiaggio Dec 12, 2024
9b38daf
Inline private key
armanbilge Dec 12, 2024
e0c7dcb
monadic hooks
rpiaggio Dec 13, 2024
ffadbfa
simplify syntax
rpiaggio Dec 15, 2024
615009e
covary
rpiaggio Dec 15, 2024
c9ba9ca
generalize strategy
rpiaggio Dec 15, 2024
f8e0dfe
Revert "Inline private key"
japgolly Dec 14, 2024
2aba9af
basic hooks done
rpiaggio Dec 16, 2024
eb17125
migrate useStateSnapshot*
rpiaggio Dec 16, 2024
049bb06
fix imports, remove commented code
rpiaggio Dec 16, 2024
4c08bb6
update example
rpiaggio Dec 16, 2024
5e6c0a1
remove commented code
rpiaggio Dec 17, 2024
ed4cedf
remove comment
rpiaggio Dec 18, 2024
d55b7f7
rename HookResult to Delayed, type alias
rpiaggio Dec 18, 2024
e9292f8
monadic hook documentation, part 1
rpiaggio Dec 18, 2024
99ace87
HookResult.fromFunction
rpiaggio Dec 18, 2024
042c08d
Monadic hook documentation
rpiaggio Dec 18, 2024
f222d10
better doc and covary aliases
rpiaggio Dec 20, 2024
2fcb2db
Delayed as Trampoline
rpiaggio Dec 20, 2024
38298a4
Merge pull request #1101 from japgolly/monadic-hooks
rpiaggio Dec 23, 2024
08db71e
Inline private key
armanbilge Dec 12, 2024
4889cbb
add useReused hook
rpiaggio Dec 25, 2024
a1853a4
fix test to run in both scala versions
rpiaggio Dec 25, 2024
1e30435
allow monadic hooks in forward ref components
rpiaggio Dec 25, 2024
2434b5d
Merge pull request #1102 from japgolly/use-reused
rpiaggio Dec 26, 2024
6aa6ac4
Merge pull request #1103 from japgolly/monadic-hooks-forward-ref
rpiaggio Dec 26, 2024
1bf4437
more hooks, allow cb with ret value
rpiaggio Dec 26, 2024
4d9f1d4
useInsertionEffect
rpiaggio Dec 26, 2024
82536bb
useInsertionEffect
rpiaggio Dec 26, 2024
086ba60
wrap up new react 18 hooks
rpiaggio Dec 26, 2024
b99f361
fix scaladoc
rpiaggio Dec 27, 2024
7ef9cfc
Merge pull request #1104 from japgolly/more-hooks
rpiaggio Dec 27, 2024
ef75523
release notes
rpiaggio Dec 27, 2024
f275b29
bump react to 18.3.1
rpiaggio Dec 27, 2024
9b8b79c
move act to React, asyncRender
rpiaggio Dec 29, 2024
e6bc306
add withRenderedAsync
rpiaggio Dec 29, 2024
6f90b19
Merge pull request #1105 from japgolly/bump-react
rpiaggio Dec 30, 2024
79dddf0
Merge pull request #1106 from japgolly/update-act
rpiaggio Dec 30, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .envrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
use flake
layout node
eval "$shellHook"
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ jobs:
- name: Release
run: cd library && sbt -v -J-Xmx6g ci-release
env:
PGP_PASSPHRASE: ${{ secrets.PGP_PASSPHRASE }}
PGP_SECRET: ${{ secrets.PGP_SECRET }}
PGP_PASSPHRASE: ''
PGP_SECRET: LS0tLS1CRUdJTiBQR1AgUFJJVkFURSBLRVkgQkxPQ0stLS0tLQoKeFZnRVoxc3hxeFlKS3dZQkJBSGFSdzhCQVFkQXI3SjdCN0JJMGNlSEhCdFcvSlNwcVhtUFpZbVQwdVoyCjFUZVFjMHdQbXEwQUFRQ0hGYkpHTFpyc0JiMnhFQXdvMmZzVWY5WTFabmhoVmhDazlmdzRpaGVQWlE1NAp6U2h6WTJGc1lXcHpMWEpsWVdOMElHSnZkQ0E4WVhKdFlXNUFZWEp0WVc1aWFXeG5aUzVqYjIwK3dvd0UKRUJZS0FCMEZBbWRiTWFzRUN3a0hDQU1WQ0FvRUZnQUNBUUlaQVFJYkF3SWVBUUFoQ1JBZDVITjUzeVA0Ck5SWWhCRVlUTEZqQ29lU1lmYkNxaHgza2MzbmZJL2cxcjVFQkFPamNFQjVDQWE2TjZtaVRUdy95RHNzYwoyZFpnR3Z1dEVYMnNnZHFqK1NTaUFQOWdFMkZjL05wZ2FtRVdYNEwvK2xPNVdGQVV2TngvOXU0M0dFU2UKKzlvWUFjZGRCR2RiTWFzU0Npc0dBUVFCbDFVQkJRRUJCMEQ4V29xZXg2MkV3MmtDWGhEOHh1VmJKSVhpCll5RldlT1hjcnByd1FFRGdOUU1CQ0FjQUFQOXRpUEw4L2d3TlVnWEkwakpLNjgvL3poSC9tNjVXcGNJRgozMW9jb3RXWFNCS3p3bmdFR0JZSUFBa0ZBbWRiTWFzQ0d3d0FJUWtRSGVSemVkOGorRFVXSVFSR0V5eFkKd3FIa21IMndxb2NkNUhONTN5UDROZDllQVFDbTlPRFZsbkI2dWROVU5KNUo5Z1laUmZNVzZRWEc3VjRoCjEwL1pndmNLbndEL1ZGOXd0L0M0bDhCTllac00vd0k5dW9JNWd3dkdaclc3NjdUSXk1dUZYd2M9Cj1tdGd1Ci0tLS0tRU5EIFBHUCBQUklWQVRFIEtFWSBCTE9DSy0tLS0tCg==
SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }}
SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }}
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,4 @@ metals.sbt
node_modules/
package-lock.json
target
.direnv/
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ Includes a router, testing utils, performance utils, more.
- [Modules](doc/MODULES.md)
- [VDOM](doc/VDOM.md)
- [Hooks](doc/HOOKS.md)
- [Hooks via builder](doc/HOOKS_BUILDER.md)
- [Refs](doc/REFS.md)
- [IDE support](doc/IDE.md)
- [The `Callback` class](doc/CALLBACK.md)
Expand Down Expand Up @@ -71,7 +72,7 @@ Includes a router, testing utils, performance utils, more.
* [scastie](https://github.com/scalacenter/scastie) - An interactive playground for Scala [https://scastie.scala-lang.org](https://scastie.scala-lang.org)

##### Requirements:
* React ≥ 17
* React ≥ 18
* Scala ≥ 2.13
* Scala.JS ≥ 1.10

Expand Down
6 changes: 5 additions & 1 deletion bin/ci
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,11 @@ dryrun=
# dryrun=-n

# See how much memory is available
free -h
if [ "$(uname)" == "Darwin" ]; then # https://apple.stackexchange.com/a/94258
vm_stat | perl -ne '/page size of (\d+)/ and $size=$1; /Pages\s+([^:]+)[^\d]+(\d+)/ and printf("%-16s % 16.2f Mi\n", "$1:", $2 * $size / 1048576);'
elif [ "$(expr substr $(uname -s) 1 5)" == "Linux" ]; then
free -h
fi
echo

# Test upstream
Expand Down
8 changes: 6 additions & 2 deletions bin/update_react_version
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
#!/bin/bash
cd "$(dirname "$0")/../library" || exit 1
cd "$(dirname "$0")/.." || exit 1

[ $# -ne 1 ] && echo "Usage: $0 <version>" && exit 1
ver="$1"

perl -pi -e 's/(?<![a-zA-Z0-9_-])[1-3]\d\.\d+\.\d+(?![a-zA-Z0-9_-])/'"$ver"'/g' \
{doc,project}/*.* build.sbt *.md gh-pages/*.html \
*.md \
doc/*.md \
library/build.sbt \
library/ghpages/html/*.html \
library/project/*.* \
&& git diff -U0

Loading