Skip to content

Commit

Permalink
chore: replace faker with @faker-js/faker
Browse files Browse the repository at this point in the history
  • Loading branch information
ppiyush13 committed Nov 15, 2022
1 parent a6c021d commit 0113d59
Show file tree
Hide file tree
Showing 8 changed files with 12 additions and 18 deletions.
2 changes: 1 addition & 1 deletion examples/auto-prepend-items.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { useCallback, useState } from 'react'
import * as React from 'react'
import { Virtuoso } from '../src'
import faker from 'faker/dist/faker.js'
import { faker } from '@faker-js/faker'

function toggleBg(index: number) {
return index % 2 ? 'var(--ifm-background-color)' : 'var(--ifm-color-emphasis-200)'
Expand Down
2 changes: 1 addition & 1 deletion examples/chat.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { useRef, useState } from 'react'
import * as React from 'react'
import styled from '@emotion/styled'
import { Virtuoso } from '../src/'
import faker from 'faker/dist/faker.js'
import { faker } from '@faker-js/faker'

interface BubbleProps {
text: string
Expand Down
2 changes: 1 addition & 1 deletion examples/grouped-endless-scrolling.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import * as React from 'react'
import { Components, GroupedVirtuoso } from '../src'
import { useMemo, useRef, useState, useEffect, useCallback } from 'react'
import faker from 'faker/dist/faker.js'
import { faker } from '@faker-js/faker'
import { groupBy } from 'lodash'

const getUser = () => {
Expand Down
2 changes: 1 addition & 1 deletion examples/grouped-load-more.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import * as React from 'react'
import { Components, GroupedVirtuoso } from '../src'
import { useMemo, useRef, useState, useEffect } from 'react'
import faker from 'faker/dist/faker.js'
import { faker } from '@faker-js/faker'
import { groupBy } from 'lodash'

const getUser = () => {
Expand Down
2 changes: 1 addition & 1 deletion examples/prepend-as-you-scroll.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import * as React from 'react'
import { Virtuoso } from '../src'
import faker from 'faker/dist/faker.js'
import { faker } from '@faker-js/faker'
import { useState, useCallback } from 'react'

const generated: Array<ReturnType<typeof user>> = []
Expand Down
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,10 @@
"@commitlint/config-conventional": "^12.1.4",
"@emotion/core": "^10.1.0",
"@emotion/styled": "^10.0.27",
"@faker-js/faker": "^7.6.0",
"@microsoft/api-extractor": "^7.25.0",
"@playwright/test": "^1.27.1",
"@testing-library/react": "^13.4.0",
"@types/faker": "^5.1.4",
"@types/jest": "^26.0.20",
"@types/jsdom": "^16.2.3",
"@types/lodash": "^4.14.165",
Expand All @@ -79,7 +79,6 @@
"eslint-plugin-prettier": "^3.3.1",
"eslint-plugin-react": "^7.20.3",
"eslint-plugin-react-hooks": "^4.0.8",
"faker": "^5.1.0",
"husky": "^6.0.0",
"jest": "^26.6.3",
"jsdom": "^16.4.0",
Expand Down
2 changes: 1 addition & 1 deletion site/docusaurus-sandpack/src/theme/CodeBlock/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import useDocusaurusContext from '@docusaurus/useDocusaurusContext'
import './style.css'

const dataCode = `
import faker from 'faker/dist/faker.js'
import { faker } from '@faker-js/faker'
import { groupBy } from 'lodash'
import React from 'react'
Expand Down
15 changes: 5 additions & 10 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1280,6 +1280,11 @@
minimatch "^3.0.4"
strip-json-comments "^3.1.1"

"@faker-js/faker@^7.6.0":
version "7.6.0"
resolved "https://registry.yarnpkg.com/@faker-js/faker/-/faker-7.6.0.tgz#9ea331766084288634a9247fcd8b84f16ff4ba07"
integrity sha512-XK6BTq1NDMo9Xqw/YkYyGjSsg44fbNwYRx7QK2CuoQgyy+f1rrTDHoExVM5PsyXCtfl2vs2vVJ0MN0yN6LppRw==

"@gar/promisify@^1.1.3":
version "1.1.3"
resolved "https://registry.yarnpkg.com/@gar/promisify/-/promisify-1.1.3.tgz#555193ab2e3bb3b6adc3d551c9c030d9e860daf6"
Expand Down Expand Up @@ -2828,11 +2833,6 @@
resolved "https://registry.yarnpkg.com/@types/estree/-/estree-0.0.39.tgz#e177e699ee1b8c22d23174caaa7422644389509f"
integrity sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw==

"@types/faker@^5.1.4":
version "5.5.9"
resolved "https://registry.yarnpkg.com/@types/faker/-/faker-5.5.9.tgz#588ede92186dc557bff8341d294335d50d255f0c"
integrity sha512-uCx6mP3UY5SIO14XlspxsGjgaemrxpssJI0Ol+GfhxtcKpv9pgRZYsS4eeKeHVLje6Qtc8lGszuBI461+gVZBA==

"@types/graceful-fs@^4.1.2":
version "4.1.5"
resolved "https://registry.yarnpkg.com/@types/graceful-fs/-/graceful-fs-4.1.5.tgz#21ffba0d98da4350db64891f92a9e5db3cdb4e15"
Expand Down Expand Up @@ -5276,11 +5276,6 @@ extglob@^2.0.4:
snapdragon "^0.8.1"
to-regex "^3.0.1"

faker@^5.1.0:
version "5.5.3"
resolved "https://registry.yarnpkg.com/faker/-/faker-5.5.3.tgz#c57974ee484431b25205c2c8dc09fda861e51e0e"
integrity sha512-wLTv2a28wjUyWkbnX7u/ABZBkUkIF2fCd73V6P2oFqEGEktDfzWx4UxrSqtPRw0xPRAcjeAOIiJWqZm3pP4u3g==

fast-deep-equal@^3.1.1, fast-deep-equal@^3.1.3:
version "3.1.3"
resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525"
Expand Down

0 comments on commit 0113d59

Please sign in to comment.