4.0.0 • Published 3 years ago

shortcut-url v4.0.0

Weekly downloads
3
License
MIT
Repository
github
Last release
3 years ago

shortcut-url

Get the URL from a web shortcut file

Install

$ npm install shortcut-url

Usage

import shortcutUrl from 'shortcut-url';

console.log(await shortcutUrl('google'));
//=> 'https://google.com'

In the above example it will look for the following file:

  • macOS: google.webloc
  • Linux: google.desktop
  • Windows: google.url

API

shortcutUrl(filePath)

Returns Promise<string> with the URL.

filePath

Type: string

The file path to the web shortcut.

Leave out the extension for cross-platform compatibility.

Related