Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

electron-spotlight

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

electron-spotlight

Add items to macOS Spotlight from Electron

  • 1.1.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

electron-spotlight

Index or remove items in macOS Spotlight, using a native Node module.

Quick-start

npm i electron-spotlight
import { addItems } from 'electron-spotlight';

addItems([{
  id: 'your-unique-identifier',
  title: 'Title In Spotlight',
  icon: 'https://pbs.twimg.com/media/CdlFCYmXIAAGkiH.jpg'
}])

API

addItems(items: Array<SearchItem>)

Index items within Spotlight. Maps to indexSearchableItems.

export interface SearchItem {
  id: string;
  title: string;
  icon?: string;
}

Note that you must be on a signed build to communicate with corespotlightd. Otherwise you'll see Unable to communicate with helper app.

removeItems(ids: Array<string>)

Removes items from Spotlight according to their unique identifier. Maps to deleteSearchableItemsWithIdentifiers.

removeAllItems()

Removes all items from Spotlight indexing. Maps to deleteAllSearchableItemsWithCompletionHandler.

Keywords

FAQs

Package last updated on 08 Mar 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

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