Socket
Socket
Sign inDemoInstall

@expo/fingerprint

Package Overview
Dependencies
Maintainers
24
Versions
62
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@expo/fingerprint - npm Package Compare versions

Comparing version 0.0.1-canary-20231205-250b31f to 0.0.1-canary-20240109-93608d8

6

package.json
{
"name": "@expo/fingerprint",
"version": "0.0.1-canary-20231205-250b31f",
"version": "0.0.1-canary-20240109-93608d8",
"description": "A library to generate a fingerprint from a React Native project",

@@ -54,7 +54,7 @@ "main": "build/index.js",

"@types/find-up": "^4.0.0",
"expo-module-scripts": "0.0.1-canary-20231205-250b31f",
"expo-module-scripts": "0.0.1-canary-20240109-93608d8",
"glob": "^7.1.7",
"temp-dir": "^2.0.0"
},
"gitHead": "250b31f516a04578a29c6bcda29aab80ef4d4e2d"
"gitHead": "93608d8dcb0268312e0c8ed22036ebfa6efe9830"
}

@@ -5,4 +5,11 @@ # @expo/fingerprint

## Usage
## Table of Contents
* [API Usage](#api-usage)
* [CLI Usage](#cli-usage)
* [Customizations](#customizations)
* [Limitations](#limitations)
## API Usage
```ts

@@ -14,6 +21,10 @@ import * as Fingerprint from '@expo/fingerprint';

### `async function createFingerprintAsync(projectRoot: string, options?: Options): Promise<Fingerprint>`
### createFingerprintAsync
Create a fingerprint from project
```ts
function createFingerprintAsync(projectRoot: string, options?: Options): Promise<Fingerprint>;
```
Example:

@@ -52,6 +63,10 @@

### `async function createProjectHashAsync(projectRoot: string, options?: Options): Promise<string>`
### createProjectHashAsync
Create a native hash value from project
```ts
function createProjectHashAsync(projectRoot: string, options?: Options): Promise<string>;
```
Example:

@@ -68,6 +83,10 @@

### `diffFingerprintChangesAsync(fingerprint: Fingerprint, projectRoot: string, options?: Options): Promise<FingerprintSource[]>`
### diffFingerprintChangesAsync
Differentiate given `fingerprint` with the current project fingerprint state
Diff the given `fingerprint` with the current project fingerprint state
```ts
function diffFingerprintChangesAsync(fingerprint: Fingerprint, projectRoot: string, options?: Options): Promise<FingerprintSource[]>;
```
Example:

@@ -120,2 +139,10 @@

### diffFingerprints
Find the diff between two fingerprints
```ts
function diffFingerprints(fingerprint1: Fingerprint, fingerprint2: Fingerprint): FingerprintSource[];
```
## CLI Usage

@@ -135,5 +162,22 @@

## Customizations
### Include or exclude extra files in the **.fingerprintignore** file
Our default ignore paths, found here [`DEFAULT_IGNORE_PATHS`](https://github.com/expo/expo/blob/main/packages/%40expo/fingerprint/src/Options.ts#L9), make hashing fast and keep hashing results stable. If the default setup does not fit your workflow, you can add a **.fingerprintignore** file in your project root. It works like [**.gitignore**](https://git-scm.com/docs/gitignore#_pattern_format) but with some slight differences: We use `minimatch` for pattern matching with the [limitations](https://github.com/expo/expo/blob/9b9133c96f209b0616d1796aadae28913f8d012f/packages/%40expo/fingerprint/src/Fingerprint.types.ts#L46-L55).
Here's how to use **.fingerprintignore**: To skip a whole folder but keep some files, you can do this:
```
# Ignore the entire /app/ios folder
/app/ios/**/*
# But still keep /app/ios/Podfile and /app/ios/Podfile.lock
!/app/ios/Podfile
!/app/ios/Podfile.lock
```
## Limitations
## Limited support for [config-plugins raw functions](https://docs.expo.dev/config-plugins/plugins-and-mods/#raw-functions)
### Limited support for [config-plugins raw functions](https://docs.expo.dev/config-plugins/plugins-and-mods/#raw-functions)

@@ -140,0 +184,0 @@ When using config-plugins with raw functions, it's essential to be aware of certain limitations, particularly in the context of fingerprinting. Expo makes its best effort to generate fingerprints for changes made through config-plugins; however, raw functions pose specific challenges. Raw functions are not serializable as fingerprints, which means they cannot be directly used for generating unique hashes.

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc