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

Fix keyed list ordering issue #1231

Merged
merged 45 commits into from
Jun 28, 2020
Merged
Changes from 1 commit
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
4c7b8e2
New example to showcase keyed elems reordering issue
totorigolo May 24, 2020
392c870
Allow building examples in release mode
totorigolo May 24, 2020
b0dcc42
Fix ordering issue with keyed virtual nodes
totorigolo May 24, 2020
be354c3
review comments for build.sh
totorigolo May 25, 2020
30edcda
review comments for examples/keyed_list
totorigolo May 25, 2020
b879414
fix style.css to keyed_list example
totorigolo May 25, 2020
be580f4
remove ahash
totorigolo May 25, 2020
0b5b83a
Add GitHub issue to TODO in key.rs
totorigolo May 25, 2020
f611bfb
Address some review comments in virtual_dom
totorigolo May 25, 2020
dc3b1c7
New diffing algorithm for keyed vlists
totorigolo May 28, 2020
50d05dd
Add forgotten dependency for yew-stdweb
totorigolo May 28, 2020
f6ede50
Add tests for vlist diffing
totorigolo May 29, 2020
526b1f6
Removed VDiffNodePosition
totorigolo May 30, 2020
ceed6a9
Fix usage of next_sibling for vlist
totorigolo May 30, 2020
f4b32ac
Fix tests for stdweb
totorigolo May 30, 2020
16ffa90
Mitigate issue with moving VLists when children are all VLists
totorigolo May 30, 2020
8fd55ba
Fix issue with inserting into vlist that is not last child
totorigolo May 31, 2020
d601af1
Refactor VDiff trait to make way for keyed list fixes
jstarry Jun 1, 2020
6234d39
Merge branch 'next-sibling' into vdiff-changes
jstarry Jun 1, 2020
b097138
Merge branch 'master' into vdiff-changes
jstarry Jun 9, 2020
78ffbee
Merge pull request #1 from jstarry/vdiff-changes
totorigolo Jun 9, 2020
b048dfa
Fix quote_spanned macro invocations
totorigolo Jun 10, 2020
45285dd
Revert some minor changes (style, Debug)
totorigolo Jun 10, 2020
5a174d5
Revert some minor changes (style, Debug)
totorigolo Jun 10, 2020
b89a163
Fix self-referencing NodeRef issue
totorigolo Jun 10, 2020
4558da2
All VList tests pass
totorigolo Jun 17, 2020
3f615d8
Fix algorithm choice in degenerated case
totorigolo Jun 17, 2020
023d83e
Remove stdweb and non keyed tests
totorigolo Jun 17, 2020
25e374c
Key from finite list of types
totorigolo Jun 17, 2020
5aca57d
WIP moving VList tests to diff_layouts
totorigolo Jun 19, 2020
7144982
Removed unnecessary Vec
totorigolo Jun 19, 2020
84a5326
Fix VComp NodeRef self linking issue
totorigolo Jun 19, 2020
dce0d09
Add logs to diff_layouts tests
totorigolo Jun 19, 2020
c4edeb5
WIP moving VList tests to diff_layouts
totorigolo Jun 19, 2020
700f7ae
WIP Failing test moving VComp
totorigolo Jun 19, 2020
d025c93
Merge branch 'master' into pr-1231
jstarry Jun 21, 2020
ea31526
Add VComp move_before
jstarry Jun 21, 2020
b1e166a
Fix list component change method
jstarry Jun 21, 2020
d37a410
Merge branch 'master' into pr-1231
jstarry Jun 21, 2020
093dd31
Fix bad merge
jstarry Jun 21, 2020
e4a98f3
Add more protection against node ref cycles
jstarry Jun 21, 2020
db38a50
Remove commented tests
jstarry Jun 21, 2020
c1a42f8
Feedback and clippy
jstarry Jun 21, 2020
5f1afdb
Failing test
jstarry Jun 22, 2020
ba3ac69
tests pass
jstarry Jun 22, 2020
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
Prev Previous commit
Next Next commit
review comments for build.sh
totorigolo committed May 25, 2020
commit be354c3281e1db9f793c01dfa3d6829556d8ebf6
14 changes: 7 additions & 7 deletions examples/build.sh
Original file line number Diff line number Diff line change
@@ -1,19 +1,18 @@
#!/usr/bin/env bash

SRCDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" # this source dir
cd "$SRCDIR" # ensure this script can be run from anywhere

# The example to build.
EXAMPLE=$1
cd "$EXAMPLE"

# Optimization level. Can be either "--debug" or "--release". Defaults to debug.
PROFILE=${2:---debug}

# src: https://gist.github.com/fbucek/f986da3cc3a9bbbd1573bdcb23fed2e1
set -e # error -> trap -> exit
function info() { echo -e "[\033[0;34m $* \033[0m]"; } # blue: [ info message ]
function fail() { FAIL="true"; echo -e "[\033[0;31mFAIL\033[0m] $*"; } # red: [FAIL]
trap 'LASTRES=$?; LAST=$BASH_COMMAND; if [[ LASTRES -ne 0 ]]; then fail "Command: \"$LAST\" exited with exit code: $LASTRES"; elif [ "$FAIL" == "true" ]; then fail finished with error; else echo -e "[\033[0;32m Finished! Run $EXAMPLE by serving the generated files in examples/static/ \033[0m]";fi' EXIT
trap 'LASTRES=$?; LAST=$BASH_COMMAND; if [[ LASTRES -ne 0 ]]; then fail "Command: \"$LAST\" exited with exit code: $LASTRES"; elif [ "$FAIL" == "true" ]; then fail finished with error; else echo -e "[\033[0;32m Finished! Run $EXAMPLE by serving the generated files in examples/static/ \033[0m]";fi' EXIT
SRCDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" # this source dir

cd "$SRCDIR/$EXAMPLE" # "$SRCDIR" ensures that this script can be run from anywhere.

# When using $CARGO_TARGET_DIR -> binary is located in different folder
# Necessary to locate build files for wasm-bindgen
@@ -27,6 +26,7 @@ else
TARGET_DIR=$TARGET_DIR/debug
fi

# Build the correct cargo build command depending on the optimization level.
cargo_build() {
if [[ "$PROFILE" = "--release" ]]; then
cargo build --release --target wasm32-unknown-unknown "$@"
@@ -41,7 +41,7 @@ if [[ $EXAMPLE == *_wp ]]; then
# wasm-pack overwrites .gitignore -> save -> restore
cp "$SRCDIR/static/.gitignore" "$SRCDIR/static/.gitignore.copy"
wasm-pack build "$PROFILE" --target web --out-name wasm --out-dir "$SRCDIR/static/"
rm "$SRCDIR/static/.gitignore"; mv "$SRCDIR/static/.gitignore.copy" $SRCDIR/static/.gitignore # restore .gitignore
rm "$SRCDIR/static/.gitignore"; mv "$SRCDIR/static/.gitignore.copy" "$SRCDIR/static/.gitignore" # restore .gitignore

# multi_thread build -> two binary/wasm files
elif [[ $EXAMPLE == multi_thread ]]; then