Skip to content
This repository has been archived by the owner on Nov 5, 2024. It is now read-only.

Commit

Permalink
Støtt React 18. Release 6.4.0
Browse files Browse the repository at this point in the history
  • Loading branch information
peterbb committed Sep 4, 2023
1 parent 393d2fb commit c6afeee
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 29 deletions.
2 changes: 1 addition & 1 deletion brukerapi-mock/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@navikt/arbeidsgiver-notifikasjoner-brukerapi-mock",
"description": "Mocker graphql-endepunkt for brukerapi. Nyttig for utvikling av @navikt/arbeidsgiver-notifikasjon-widget.",
"repository": "github:navikt/arbeidsgiver-notifikasjon-widget",
"version": "6.3.9",
"version": "6.4.0",
"license": "MIT",
"main": "dist/notifikasjonMockMiddleware.js",
"files": [
Expand Down
36 changes: 18 additions & 18 deletions component/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions component/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@navikt/arbeidsgiver-notifikasjon-widget",
"description": "React component for notifikasjoner for arbeidsgivere",
"repository": "github:navikt/arbeidsgiver-notifikasjon-widget",
"version": "6.3.9",
"version": "6.4.0",
"main": "./lib/cjs/index.js",
"module": "./lib/esm/index.js",
"types": "./lib/esm/lib/esm/index.d.ts",
Expand Down Expand Up @@ -40,8 +40,8 @@
"typescript": "^4.8.4"
},
"peerDependencies": {
"react": "17",
"react-dom": "17",
"react": "17 | 18",
"react-dom": "17 | 18",
"@navikt/ds-css": ">=2",
"@navikt/ds-icons": ">=2",
"@navikt/ds-react": ">=2"
Expand Down
5 changes: 3 additions & 2 deletions component/src/utils/amplitude.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import amplitude, {AmplitudeClient} from 'amplitude-js'
import {Notifikasjon} from '../api/graphql-types'
import React, {createContext, FC, useContext, useMemo} from "react";
import React, {createContext, ReactNode, useContext, useMemo} from "react";
import {Miljø} from "../index";

const createAmpltiudeInstance = (apiKey: string) => {
Expand Down Expand Up @@ -79,9 +79,10 @@ const AmplitudeContext = createContext(createAmplitudeLogger(stubbedAmplitudeCli

type Props = {
miljo: Miljø,
children: ReactNode,
}

export const AmplitudeProvider: FC<Props> = ({miljo, children}) => {
export const AmplitudeProvider = ({miljo, children}: Props) => {
const client = useAmplitudeClient(miljo)
const logger = createAmplitudeLogger(client)
return <AmplitudeContext.Provider value={logger}>
Expand Down
10 changes: 5 additions & 5 deletions demo/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit c6afeee

Please sign in to comment.