Skip to content

Commit

Permalink
build(deps-dev): update dev dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
JohnAlbin committed Feb 21, 2024
1 parent f04c617 commit 477718d
Show file tree
Hide file tree
Showing 8 changed files with 3,815 additions and 4,017 deletions.
54 changes: 27 additions & 27 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,46 +32,46 @@
"test:e2e:ci": "turbo run test:e2e:ci --parallel"
},
"resolutions": {
"@types/react": "17.0.68",
"@types/react-dom": "17.0.21"
"@types/react": "17.0.75",
"@types/react-dom": "17.0.25"
},
"devDependencies": {
"@actions/core": "^1.10.1",
"@babel/core": "^7.23.2",
"@babel/eslint-parser": "^7.22.15",
"@babel/plugin-transform-runtime": "^7.23.2",
"@babel/preset-env": "^7.23.2",
"@babel/preset-react": "^7.22.15",
"@commitlint/cli": "^18.6.0",
"@commitlint/config-conventional": "^17.8.0",
"@babel/core": "^7.23.9",
"@babel/eslint-parser": "^7.23.10",
"@babel/plugin-transform-runtime": "^7.23.9",
"@babel/preset-env": "^7.23.9",
"@babel/preset-react": "^7.23.3",
"@commitlint/cli": "^18.6.1",
"@commitlint/config-conventional": "^18.6.2",
"@next/eslint-plugin-next": "^12.3.4",
"@testing-library/cypress": "^8.0.7",
"@types/jest": "^27.5.2",
"@types/node": "^17.0.45",
"@types/react": "^17.0.68",
"@types/react-dom": "^17.0.21",
"@types/jest": "^29.5.12",
"@types/node": "^20.11.19",
"@types/react": "^17.0.75",
"@types/react-dom": "^17.0.25",
"@typescript-eslint/eslint-plugin": "^7.0.2",
"@typescript-eslint/parser": "^5.62.0",
"@typescript-eslint/parser": "^7.0.2",
"cypress": "^9.7.0",
"eslint": "^8.51.0",
"eslint-config-prettier": "^9.0.0",
"eslint": "^8.56.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-cypress": "^2.15.1",
"eslint-plugin-prettier": "^5.0.1",
"eslint-plugin-prettier": "^5.1.3",
"eslint-plugin-react": "^7.33.2",
"faker": "^6.6.6",
"husky": "^9.0.11",
"isomorphic-fetch": "^3.0.0",
"jest": "^27.5.1",
"lerna": "^8.0.1",
"lint-staged": "^15.0.2",
"prettier": "^3.0.3",
"jest": "^29.7.0",
"lerna": "^8.1.2",
"lint-staged": "^15.2.2",
"prettier": "^3.2.5",
"start-server-and-test": "^1.15.5",
"ts-jest": "^27.1.5",
"ts-node": "^10.9.1",
"tsup": "^7.3.0",
"turbo": "^1.10.15",
"typescript": "^5.2.2",
"ts-jest": "^29.1.2",
"ts-node": "^10.9.2",
"tsup": "^8.0.2",
"turbo": "^1.12.4",
"typescript": "^5.3.3",
"uuid": "^9.0.1",
"yaml": "^2.3.3"
"yaml": "^2.3.4"
}
}
20 changes: 12 additions & 8 deletions packages/next-drupal-query/jest.config.cjs
Original file line number Diff line number Diff line change
@@ -1,25 +1,29 @@
/** @type {import('ts-jest/dist/types').InitialOptionsTsJest} */
/** @type {import('ts-jest').JestConfigWithTsJest} */
module.exports = {
preset: "ts-jest/presets/js-with-ts",
testEnvironment: "node",
setupFiles: ["dotenv/config"],
setupFilesAfterEnv: ["<rootDir>/jest.setup.ts"],
testMatch: ["**/tests/**/*.test.{ts,tsx}"],
globals: {
"ts-jest": {
isolatedModules: true,
},
transform: {
"^.+\\.tsx?$": [
"ts-jest",
{
isolatedModules: true,
},
],
},
testLocationInResults: true,
coverageProvider: "v8",
collectCoverage: true,
collectCoverageFrom: ["./src/**"],
coverageReporters: ["lcov", "text", "text-summary"],
coverageThreshold: {
global: {
statements: 85.11,
branches: 58,
statements: 84.22,
branches: 64.1,
functions: 70,
lines: 85.11,
lines: 84.22,
},
},
}
6 changes: 3 additions & 3 deletions packages/next-drupal-query/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ export function withPagination(
}
}

if (typeof opts.page !== undefined && typeof opts.limit !== undefined) {
if (typeof opts.page !== "undefined" && typeof opts.limit !== "undefined") {
params.addPageLimit(opts.limit).addPageOffset(opts.page * opts.limit)
}

Expand Down Expand Up @@ -292,8 +292,8 @@ export function createQueries<Q extends Readonly<Queries<Q>>>(queries: Q) {
opts = massageRouteQuery(opts)

if (
typeof query["defaultOpts"] !== undefined &&
typeof opts !== undefined
typeof query["defaultOpts"] !== "undefined" &&
typeof opts !== "undefined"
) {
// eslint-disable-next-line @typescript-eslint/no-explicit-any
opts = deepmerge(query["defaultOpts"], opts as any) as any
Expand Down
42 changes: 21 additions & 21 deletions packages/next-drupal-query/tests/__snapshots__/index.test.ts.snap
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`formatData it formats data 1`] = `
Object {
{
"name": "First Last",
}
`;

exports[`getData it accepts data options 1`] = `
Object {
{
"author": "shadcn",
"id": "ID",
"title": "Title of Article",
Expand All @@ -16,14 +16,14 @@ Object {
`;

exports[`getData it accepts placeholder options 1`] = `
Object {
{
"email": "[email protected]",
"name": "shadcn",
}
`;

exports[`getData it returns data for a query 1`] = `
Object {
{
"author": "shadcn",
"id": "id",
"title": "Title of Article",
Expand All @@ -32,52 +32,52 @@ Object {
`;

exports[`getData it returns data when both data and placeholder is defined 1`] = `
Object {
{
"email": "[email protected]",
}
`;

exports[`getData it returns formatted data if a formatter is defined 1`] = `
Object {
{
"email": "[email protected]",
"name": "First Last",
}
`;

exports[`getData it returns placeholder data if a query does not define data 1`] = `
Object {
{
"name": "shadcn",
}
`;

exports[`getParams it accepts params options 1`] = `
Object {
"fields": Object {
{
"fields": {
"resource": "foo,bar",
},
"filter": Object {},
"include": Array [],
"sort": Array [],
"filter": {},
"include": [],
"sort": [],
}
`;

exports[`getParams it allows params to be nested 1`] = `
Object {
"fields": Object {},
"filter": Object {},
{
"fields": {},
"filter": {},
"include": "field_image,uid",
"page": Object {
"page": {
"limit": 10,
},
"sort": Array [],
"sort": [],
}
`;

exports[`getParams it returns params for a query 1`] = `
Object {
"fields": Object {},
"filter": Object {},
{
"fields": {},
"filter": {},
"include": "field_image,uid",
"sort": Array [],
"sort": [],
}
`;
13 changes: 8 additions & 5 deletions packages/next-drupal/jest.config.cjs
Original file line number Diff line number Diff line change
@@ -1,14 +1,17 @@
/** @type {import('ts-jest/dist/types').InitialOptionsTsJest} */
/** @type {import('ts-jest').JestConfigWithTsJest} */
module.exports = {
preset: "ts-jest",
testEnvironment: "node",
setupFiles: ["dotenv/config"],
setupFilesAfterEnv: ["<rootDir>/jest.setup.ts"],
testMatch: ["**/tests/**/*.test.{ts,tsx}"],
globals: {
"ts-jest": {
isolatedModules: true,
},
transform: {
"^.+\\.tsx?$": [
"ts-jest",
{
isolatedModules: true,
},
],
},
coverageProvider: "v8",
collectCoverage: true,
Expand Down
2 changes: 1 addition & 1 deletion packages/next-drupal/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@
"directory": "packages/next-drupal"
},
"devDependencies": {
"typescript": "^5.2.2"
"typescript": "^5.3.3"
},
"dependencies": {
"jsona": "^1.12.1",
Expand Down
Loading

0 comments on commit 477718d

Please sign in to comment.