Skip to content

Commit

Permalink
(chore) O3-1514: Upgrade Yarn to berry (#73)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jexsie committed May 18, 2023
1 parent 204d53f commit 90dfd4b
Show file tree
Hide file tree
Showing 11 changed files with 15,982 additions and 9,727 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/node.js.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ jobs:
with:
node-version: "18"
registry-url: "https://registry.npmjs.org"
- run: yarn install --immuatable
- run: yarn install --immutable
- run: yarn version --new-version "$(node -e "console.log(require('semver').inc(require('./package.json').version, 'patch'))")-pre.${{ github.run_number }}" --no-git-tag-version
- run: yarn build
- run: yarn publish --access public --tag next
Expand Down
9 changes: 9 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,15 @@ npm-debug.log*
yarn-debug.log*
yarn-error.log*

# ignores for Yarn v3 w/o PNP
.pnp.*
.yarn/*
!.yarn/patches
!.yarn/plugins
!.yarn/releases
!.yarn/sdks
!.yarn/versions

# Runtime data
pids
*.pid
Expand Down
541 changes: 541 additions & 0 deletions .yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs

Large diffs are not rendered by default.

873 changes: 873 additions & 0 deletions .yarn/releases/yarn-3.5.1.cjs

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions .yarnrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
nodeLinker: node-modules

plugins:
- path: .yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs
spec: "@yarnpkg/plugin-interactive-tools"

yarnPath: .yarn/releases/yarn-3.5.1.cjs
15 changes: 15 additions & 0 deletions jest.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
module.exports = {
transform: {
"^.+\\.tsx?$": "@swc/jest",
},
transformIgnorePatterns: ["/node_modules/(?!@openmrs)"],
moduleNameMapper: {
"@openmrs/esm-framework": "@openmrs/esm-framework/mock",
"\\.(s?css)$": "identity-obj-proxy",
"^lodash-es/(.*)$": "lodash/$1",
"^uuid$": "<rootDir>/node_modules/uuid/dist/index.js",
dexie: require.resolve("dexie"),
},
setupFilesAfterEnv: ["<rootDir>/src/setup-tests.ts"],
testEnvironment: "jsdom",
};
18 changes: 0 additions & 18 deletions jest.config.json

This file was deleted.

13 changes: 7 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@
"analyze": "webpack --mode=production --env.analyze=true",
"prettier": "prettier --write \"src/**/*.{ts,tsx}\"",
"lint": "eslint src --ext js,jsx,ts,tsx",
"test": "jest --config jest.config.json",
"test": "jest --config jest.config.js",
"typescript": "tsc",
"verify": "concurrently 'yarn:lint' 'yarn:test' 'yarn:typescript'",
"coverage": "yarn test --coverage",
"prepare": "husky install"
"postinstall": "husky install"
},
"browserslist": [
"extends browserslist-config-openmrs"
Expand All @@ -41,17 +41,16 @@
"url": "https://github.com/openmrs/openmrs-esm-dispensing/issues"
},
"dependencies": {
"@carbon/react": "^1.9.0",
"@carbon/react": "1.12.0",
"lodash-es": "^4.17.15",
"swr": "^2.1.0"
},
"peerDependencies": {
"@openmrs/esm-framework": "4.x",
"@openmrs/esm-framework": "*",
"dayjs": "1.x",
"react": "18.x",
"react-dom": "18.x",
"react-i18next": "11.x",
"react-router-dom": "6.x",
"rxjs": "6.x"
},
"devDependencies": {
Expand All @@ -70,6 +69,7 @@
"@types/webpack-env": "^1.16.0",
"@typescript-eslint/parser": "^4.26.0",
"concurrently": "^6.2.0",
"dayjs": "1.x",
"eslint": "^7.27.0",
"eslint-config-prettier": "^8.3.0",
"eslint-config-ts-react-important-stuff": "^3.0.0",
Expand All @@ -89,5 +89,6 @@
"react-router-dom": "^6.3.0",
"rxjs": "^6.5.4",
"typescript": "^4.3.2"
}
},
"packageManager": "yarn@3.5.1"
}
2 changes: 2 additions & 0 deletions src/declarations.d.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
declare module "*.css";
declare module "*.scss";
declare module "*.svg";
declare module "@carbon/react";
declare type SideNavProps = {};
2 changes: 1 addition & 1 deletion src/types.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { OpenmrsResource } from "@openmrs/esm-api";
import { OpenmrsResource } from "@openmrs/esm-framework";

export interface AllergyIntolerance {
resourceType: string;
Expand Down
Loading

0 comments on commit 90dfd4b

Please sign in to comment.