mirror of
https://github.com/sveltejs/svelte.git
synced 2024-12-01 17:30:59 +01:00
[docs] fix typo in Context API tutorial (#7063)
This commit is contained in:
parent
6f2ebaa76d
commit
72d40e99b0
@ -11,7 +11,7 @@ There are two halves to the context API — `setContext` and `getContext`. If a
|
||||
Let's set the context first. In `Map.svelte`, import `setContext` from `svelte` and `key` from `mapbox.js` and call `setContext`:
|
||||
|
||||
```js
|
||||
import { onMount, setContext } from 'svelte';
|
||||
import { onDestroy, setContext } from 'svelte';
|
||||
import { mapbox, key } from './mapbox.js';
|
||||
|
||||
setContext(key, {
|
||||
|
Loading…
Reference in New Issue
Block a user