From 3b0a9c84dbefb15543fa002ab63534b850f5bb63 Mon Sep 17 00:00:00 2001 From: Matt McCoy Date: Tue, 13 Feb 2024 13:44:47 -0500 Subject: [PATCH 1/2] fix: pls work --- client/.eslintrc | 2 +- client/babel.config.js | 3 ++- client/declaration.d.ts | 7 ------- client/nativewind.d.ts | 8 ++++++++ client/package.json | 20 ++++++++++---------- client/tailwind.config.js | 8 +------- 6 files changed, 22 insertions(+), 26 deletions(-) delete mode 100644 client/declaration.d.ts diff --git a/client/.eslintrc b/client/.eslintrc index 1f85151..59197be 100644 --- a/client/.eslintrc +++ b/client/.eslintrc @@ -50,7 +50,7 @@ }, "overrides": [ { - "files": ["screens/**/*", "App.tsx", "declaration.d.ts"], + "files": ["screens/**/*", "App.tsx", "nativewind.d.ts"], "rules": { // Allows default exports for the above files "import/no-default-export": "off" diff --git a/client/babel.config.js b/client/babel.config.js index 6fa972e..9b1d991 100644 --- a/client/babel.config.js +++ b/client/babel.config.js @@ -1,7 +1,8 @@ module.exports = function (api) { api.cache(true); + return { presets: ['babel-preset-expo'], - plugins: ['react-native-paper/babel', 'nativewind/babel'] + plugins: ['nativewind/babel'] }; }; diff --git a/client/declaration.d.ts b/client/declaration.d.ts deleted file mode 100644 index fe78ee8..0000000 --- a/client/declaration.d.ts +++ /dev/null @@ -1,7 +0,0 @@ -declare module '*.svg' { - import React from 'react'; - - import { SvgProps } from 'react-native-svg'; - const content: React.FC; - export default content; -} diff --git a/client/nativewind.d.ts b/client/nativewind.d.ts index a13e313..7467561 100644 --- a/client/nativewind.d.ts +++ b/client/nativewind.d.ts @@ -1 +1,9 @@ /// + +declare module '*.svg' { + import React from 'react'; + + import { SvgProps } from 'react-native-svg'; + const content: React.FC; + export default content; +} diff --git a/client/package.json b/client/package.json index 4eba5b0..7889b93 100644 --- a/client/package.json +++ b/client/package.json @@ -4,7 +4,7 @@ "main": "node_modules/expo/AppEntry.js", "scripts": { "ts:check": "tsc", - "start": "expo start", + "start": "expo start --reset-cache", "android": "expo start --android", "ios": "expo start --ios", "web": "expo start --web", @@ -15,24 +15,24 @@ }, "dependencies": { "@firebase/auth": "^1.5.1", - "@react-native-async-storage/async-storage": "1.18.2", + "@react-native-async-storage/async-storage": "1.21.0", "@react-navigation/bottom-tabs": "^6.5.11", "@react-navigation/native": "^6.1.9", "@react-navigation/native-stack": "^6.9.17", "@tanstack/react-query": "^5.18.1", "axios": "^1.6.4", "clsx": "^2.1.0", - "expo": "~49.0.13", - "expo-document-picker": "~11.5.4", - "expo-file-system": "~15.4.5", - "expo-status-bar": "~1.6.0", + "expo": "^50.0.6", + "expo-document-picker": "~11.10.1", + "expo-file-system": "~16.0.6", + "expo-status-bar": "~1.11.1", "firebase": "^10.7.2", "nativewind": "^2.0.11", "react": "18.2.0", - "react-native": "0.72.6", + "react-native": "0.73.4", "react-native-paper": "^5.12.3", - "react-native-safe-area-context": "4.6.3", - "react-native-screens": "~3.22.0", + "react-native-safe-area-context": "4.8.2", + "react-native-screens": "~3.29.0", "react-native-svg-transformer": "^1.3.0" }, "devDependencies": { @@ -50,7 +50,7 @@ "eslint-plugin-react": "^7.33.2", "prettier": "^3.2.5", "prettier-plugin-tailwindcss": "^0.5.11", - "tailwindcss": "3.3.2", + "tailwindcss": "^3.3.2", "typescript": "^5.1.3" }, "private": true diff --git a/client/tailwind.config.js b/client/tailwind.config.js index e4c198a..a55a506 100644 --- a/client/tailwind.config.js +++ b/client/tailwind.config.js @@ -1,12 +1,6 @@ /** @type {import('tailwindcss').Config} */ module.exports = { - content: [ - './**/*.html', - './**/*.js', - './**/*.jsx', - './**/*.ts', - './**/*.tsx' - ], + content: ['./App.tsx', './components/**/*.tsx', './screens/**/*.tsx'], theme: { colors: { 'carewallet-white': '#FFFFFF', From e1328ae1f50efe6ca6c89034762eebacb1d84096 Mon Sep 17 00:00:00 2001 From: Matt McCoy Date: Tue, 13 Feb 2024 15:58:12 -0500 Subject: [PATCH 2/2] build: fix eslint, and enforce tailwind and expo versions --- client/babel.config.js | 2 +- client/package.json | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/client/babel.config.js b/client/babel.config.js index 9b1d991..3bcdc6f 100644 --- a/client/babel.config.js +++ b/client/babel.config.js @@ -3,6 +3,6 @@ module.exports = function (api) { return { presets: ['babel-preset-expo'], - plugins: ['nativewind/babel'] + plugins: ['react-native-paper/babel', 'nativewind/babel'] }; }; diff --git a/client/package.json b/client/package.json index 7889b93..e70c837 100644 --- a/client/package.json +++ b/client/package.json @@ -20,9 +20,10 @@ "@react-navigation/native": "^6.1.9", "@react-navigation/native-stack": "^6.9.17", "@tanstack/react-query": "^5.18.1", + "@types/react": "^18.2.55", "axios": "^1.6.4", "clsx": "^2.1.0", - "expo": "^50.0.6", + "expo": "50.0.6", "expo-document-picker": "~11.10.1", "expo-file-system": "~16.0.6", "expo-status-bar": "~1.11.1", @@ -38,9 +39,8 @@ "devDependencies": { "@babel/core": "^7.20.0", "@trivago/prettier-plugin-sort-imports": "^4.3.0", - "@types/react": "~18.2.14", "@typescript-eslint/eslint-plugin": "^6.21.0", - "@typescript-eslint/parser": "^6.21.0", + "@typescript-eslint/parser": "6.18.0", "eslint": "^8.56.0", "eslint-config-prettier": "^9.1.0", "eslint-import-resolver-typescript": "^3.6.1", @@ -50,7 +50,7 @@ "eslint-plugin-react": "^7.33.2", "prettier": "^3.2.5", "prettier-plugin-tailwindcss": "^0.5.11", - "tailwindcss": "^3.3.2", + "tailwindcss": "3.3.2", "typescript": "^5.1.3" }, "private": true