diff --git a/README.md b/README.md index 6383109f..c2430400 100644 --- a/README.md +++ b/README.md @@ -127,6 +127,8 @@ **(boolean)** - works with [Expo Go](https://docs.expo.dev/get-started/expo-go/) — an open-source sandbox app, without using [dev clients](https://docs.expo.dev/develop/development-builds/introduction/) or [prebuild](https://docs.expo.dev/workflow/continuous-native-generation/). - #### `fireos` **(boolean)** - works on Amazon Fire OS. +- #### `vegaos` + **(boolean)** - works with [Vega OS](https://developer.amazon.com/docs/react-native-vega/0.72/react_overview.html). > [!TIP] > **Any** library can be used with Expo, if you use dev clients or prebuild. @@ -173,7 +175,7 @@ You should be able to visit `localhost:3000` in your browser. - Visit https://github.com/settings/developers to get your keys (don't worry about the callback URL, put whatever you want). - Load the `GITHUB_TOKEN` environment variable into your shell. -- Set `ONLY_WRITE_LOCAL_DATA_FILE` to `true` in *scripts/build-and-score-data.ts* to skip fetching and updating store blob from Vercel and instead use and update the local `assets/data.json` file. +- Set `ONLY_WRITE_LOCAL_DATA_FILE` to `true` in *scripts/build-and-score-data.ts* to skip fetching and updating store blob from Vercel and instead use and update the local `assets/data.json` file. This command creates site data in `./assets/data.json` @@ -202,28 +204,28 @@ https://reactnative.directory/api/libraries ``` https://reactnative.directory/api/libraries?search=webgl ``` - - - Returns a list of all libraries in `JSON` format that have the keyword `webgl`. - + +- Returns a list of all libraries in `JSON` format that have the keyword `webgl`. + ``` https://reactnative.directory/api/libraries?search=webgl&expoGo=true ``` - - - Returns a list of all libraries in `JSON` format that have the keyword `webgl` and work with Expo Go app. - + +- Returns a list of all libraries in `JSON` format that have the keyword `webgl` and work with Expo Go app. + ``` https://reactnative.directory/api/libraries?search=webgl&expoGo=true&android=true ``` - - - Returns a list of all libraries in `JSON` format that have the keyword `webgl`, work with Expo Go app and Android. - + +- Returns a list of all libraries in `JSON` format that have the keyword `webgl`, work with Expo Go app and Android. + ``` https://reactnative.directory/api/libraries?search=webgl&expoGo=true&android=true&isPopular=true ``` - - - Returns a list of all libraries in `JSON` format that have the keyword `webgl`, work with Expo Go app, Android and are popular based on the scoring criterion. - - All the possible query parameters represents [`Query` type](https://github.com/react-native-community/directory/blob/main/types/index.ts#L14-L36). + +- Returns a list of all libraries in `JSON` format that have the keyword `webgl`, work with Expo Go app, Android and are popular based on the scoring criterion. + +All the possible query parameters represents [`Query` type](https://github.com/react-native-community/directory/blob/main/types/index.ts#L14-L36). ## I don't like how you calculate scores. @@ -240,4 +242,4 @@ https://reactnative.directory/api/libraries ```sh # once environment variables are configured, install Vercel and deploy bunx vercel -``` +``` \ No newline at end of file diff --git a/components/CompatibilityTags.tsx b/components/CompatibilityTags.tsx index 3a956bb6..0c64eb76 100644 --- a/components/CompatibilityTags.tsx +++ b/components/CompatibilityTags.tsx @@ -64,7 +64,7 @@ export function CompatibilityTags({ library }: Props) { /> ) : null )} - {(library.expoGo || library.fireos) && ( + {(library.expoGo || library.fireos || library.vegaos) && ( {library.expoGo &&
  • Works with Expo Go
  • } {library.fireos &&
  • Works with Fire OS
  • } + {library.vegaos &&
  • Works with Vega OS
  • }
    )} diff --git a/components/Filters/helpers.ts b/components/Filters/helpers.ts index e08afc31..9ffbb238 100644 --- a/components/Filters/helpers.ts +++ b/components/Filters/helpers.ts @@ -87,6 +87,10 @@ export const FILTER_COMPATIBILITY: FilterParamsType[] = [ param: 'fireos', title: 'Works with Fire OS', }, + { + param: 'vegaos', + title: 'Works with Vega OS', + }, ]; export const FILTER_TYPE: FilterParamsType[] = [ diff --git a/pages/api/libraries/index.ts b/pages/api/libraries/index.ts index 478492b5..e34400e5 100644 --- a/pages/api/libraries/index.ts +++ b/pages/api/libraries/index.ts @@ -74,6 +74,7 @@ export default function handler(req: NextApiRequest, res: NextApiResponse) { fireos: parsedQuery.fireos, tvos: parsedQuery.tvos, visionos: parsedQuery.visionos, + vegaos: parsedQuery.vegaos, }, hasExample: parsedQuery.hasExample, hasImage: parsedQuery.hasImage, diff --git a/react-native-libraries.schema.json b/react-native-libraries.schema.json index 427ca5c0..1139d4d5 100644 --- a/react-native-libraries.schema.json +++ b/react-native-libraries.schema.json @@ -76,6 +76,13 @@ true ] }, + "vegaos": { + "$id": "#/items/properties/vegaos", + "type": "boolean", + "title": "Package is compatible with Vega OS", + "default": false, + "examples": [true] + }, "expoGo": { "$id": "#/items/properties/expo", "type": "boolean", @@ -218,4 +225,4 @@ } } } -} +} \ No newline at end of file diff --git a/types/index.ts b/types/index.ts index 00a3ab11..bcce81d7 100644 --- a/types/index.ts +++ b/types/index.ts @@ -22,6 +22,7 @@ export type Query = { fireos?: string; tvos?: string; visionos?: string; + vegaos?: string; web?: string; windows?: string; order?: QueryOrder; @@ -135,6 +136,7 @@ export type LibraryDataEntryType = { fireos?: boolean; tvos?: boolean; visionos?: boolean; + vegaos?: boolean; unmaintained?: boolean; dev?: boolean; template?: boolean; diff --git a/util/Constants.ts b/util/Constants.ts index e5bd8bec..4fd0be39 100644 --- a/util/Constants.ts +++ b/util/Constants.ts @@ -11,6 +11,7 @@ export const VALID_ENTRY_KEYS = new Set([ 'fireos', 'tvos', 'visionos', + 'vegaos', 'unmaintained', 'dev', 'template', diff --git a/util/search.ts b/util/search.ts index f5986c6d..a72c58b0 100644 --- a/util/search.ts +++ b/util/search.ts @@ -153,6 +153,10 @@ export function handleFilterLibraries({ return false; } + if (support.vegaos && !library.vegaos) { + return false; + } + if (support.fireos && !library.fireos) { return false; }