Skip to content

Commit

Permalink
More readable code examples
Browse files Browse the repository at this point in the history
  • Loading branch information
LachlanArthur committed Apr 14, 2020
1 parent aaa14d0 commit ebd2798
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 12 deletions.
15 changes: 15 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
root = true

[*]
indent_style = space
indent_size = 2
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true

[*.md]
indent_style = space
indent_size = 2
trim_trailing_whitespace = false
insert_final_newline = false
24 changes: 12 additions & 12 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ const scroll = getScrollSnapPositions( scrollingElement );

/*
{
x: [ 0, 100, 150, 200 ],
y: [ 0, 200, 400, 600, 800 ],
x: [ 0, 100, 150, 200 ],
y: [ 0, 200, 400, 600, 800 ],
}
*/
```
Expand All @@ -52,16 +52,16 @@ const snap = getSnapPositions( scrollingElement );

/*
{
x: {
start: [ 0, 100 ],
center: [ 300 ],
end: [ 500 ],
},
y: {
start: [ 0 ],
center: [ 250, 500, 750 ],
end: [ 1000 ],
},
x: {
start: [ 0, 100 ],
center: [ 300 ],
end: [ 500 ],
},
y: {
start: [ 0 ],
center: [ 250, 500, 750 ],
end: [ 1000 ],
},
}
*/
```
Expand Down

0 comments on commit ebd2798

Please sign in to comment.