Socket
Socket
Sign inDemoInstall

svelte-algolia

Package Overview
Dependencies
Maintainers
1
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

svelte-algolia - npm Package Compare versions

Comparing version 0.1.1 to 0.1.2

license

31

package.json
{
"name": "svelte-algolia",
"version": "0.1.1",
"version": "0.1.2",
"description": "Algolia plugin for Svelte",
"main": "index.js",
"main": "src/index.js",
"module": "src/main.js",
"repository": "https://github.com/janosh/svelte-algolia",
"homepage": "https://github.com/janosh/svelte-algolia#readme",
"bugs": {
"url": "https://github.com/janosh/svelte-algolia/issues"
},
"author": "Janosh Riebesell",
"license": "MIT",
"private": false,
"type": "module",
"devDependencies": {
"algoliasearch": "^4.5.1"
"algoliasearch": "^4.5.1",
"ava": "^3.13.0",
"eslint": "^7.12.1",
"esm": "^3.2.25",
"prettier": "^2.1.2"
},
"scripts": {
"test": "ava",
"prepublish": "ava"
},
"files": [
"src/**/*.js"
],
"keywords": [
"algolia",
"plugin"
],
"prettier": {
"semi": false,
"singleQuote": true
}
}

@@ -7,4 +7,38 @@ <p align="center">

```sh
yarn add -D svelte-algolia
```
## Usage
1. Install with `yarn` or `npm`
```sh
yarn add -D svelte-algolia
```
```sh
npm i -D svelte-algolia
```
2. Create an `algoliaConfig`:
```js
const algoliaConfig = {
appId: secrets.algoliaAppId,
apiKey: secrets.algoliaAdminKey,
partialUpdates: true,
indices: [
{ name: `pokedex`, getData: pokemonDataLoader },
{ name: `hitchHikersGuide`, getData: guideGetter },
],
}
```
3. Pass your config to the `indexAlgolia` export from this package:
```js
import { indexAlgolia } from 'svelte-algolia'
indexAlgolia(algoliaConfig)
```
## Contribute
PRs are welcome but best open an issue first to discuss any changes.
index.js
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