https://github.com/frontify/frontify-finder
Frontify Finder v2
https://github.com/frontify/frontify-finder
Last synced: over 1 year ago
JSON representation
Frontify Finder v2
- Host: GitHub
- URL: https://github.com/frontify/frontify-finder
- Owner: Frontify
- License: mit
- Created: 2021-09-24T13:41:34.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2024-10-24T12:45:13.000Z (over 1 year ago)
- Last Synced: 2025-03-15T03:16:20.002Z (over 1 year ago)
- Language: TypeScript
- Homepage:
- Size: 159 KB
- Stars: 0
- Watchers: 4
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Frontify Finder v2
Authenticate, search and access Frontify assets data from any secure web app.
**This package is tightly coupled with the [FrontifyAuthenticator](https://github.com/Frontify/frontify-authenticator) package (@frontify/frontify-authenticator) as it's being used as an internal dependency of the Frontify Finder v2.**
# Install
There are three possible ways of installing or requiring the Frontify Finder v2.
## NPM
Installing the latest published package on a third party app is as simple as running `npm i @frontify/frontify-finder` and requiring the main class either via CommonJs or as an ES module.
```js
// CommonJs require
const FrontifyFinder = require('@frontify/frontify-finder');
```
**or**
```js
// ESM import
import { create, logout } from '@frontify/frontify-finder';
```
## CDN
Alternatively, in case you're not relying on npm packages in your web app, you can also require the minified JS script directly by using a CDN such as UNPKG. You can find the latest [Frontify Finder v2](https://unpkg.com/@frontify/frontify-finder@latest/dist/index.js) source code and import it to your project you by requiring it via a `` HTML element.
```html
<script src="https://unpkg.com/@frontify/frontify-finder@latest/dist/index.js">
```
You may want to require a specific version. To do so you only have to change the word `latest` with the specific version you wish to use (ie. v2.0.0).
To make use of the available methods in the script all you have to do is use the `FrontifyFinder` object references attached to the `window`.
Example:
```js
FrontifyFinder.open(...);
```
**or**
```js
window.FrontifyFinder.open(...);
```
## LOCAL
To install any package locally doesn't differ greatly from the CDN use case. You can use the link mentioned above [here](https://unpkg.com/@frontify/frontify-finder@latest/dist/index.js) to download the files contents, save it to your local instance and require via `` HTML element making the `src` address point to your local file.
```html
<script src="<PATH_TO_FILE>/<FILENAME>.js">
```
Like mentioned in the CDN case, if may want to require a specific version, all you have to do is change the word `latest` with the specific version you wish to use (ie. v2.0.0).
You must be aware that, in this case, the latest code won't be automatically updated so it relies on manual downloads everytime you want to have a new version come into effect within your web app.