Skip to content

Commit

Permalink
Revert "Format"
Browse files Browse the repository at this point in the history
This reverts commit ca5755e.
  • Loading branch information
bryanmylee committed Aug 10, 2023
1 parent cd21476 commit f5bdce7
Showing 1 changed file with 16 additions and 16 deletions.
32 changes: 16 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,13 +44,13 @@ If the parent store is nullable, then the child store will also be nullable.

```ts
type User = {
name: {
first: string;
last: string;
};
relations: {
partner?: User;
};
name: {
first: string;
last: string;
};
relations: {
partner?: User;
};
};

const maybeUser = writable<User | undefined>(undefined);
Expand Down Expand Up @@ -152,14 +152,14 @@ One important method to reduce clutter on your component is to extract functiona

```js
export const trackClicks = (node, clicks) => {
const listen = () => {
clicks.update(($clicks) => $clicks + 1);
};
node.addEventListener('click', listen);
return {
destroy() {
node.removeEventListener('click', listen);
},
};
const listen = () => {
clicks.update(($clicks) => $clicks + 1);
};
node.addEventListener('click', listen);
return {
destroy() {
node.removeEventListener('click', listen);
},
};
};
```

0 comments on commit f5bdce7

Please sign in to comment.