mirror of
https://github.com/wassname/DefinitelyTyped.git
synced 2026-08-28 12:43:06 +08:00
Merge pull request #6748 from radek-holy/master-add-file-url
Add definitions for temp-fs
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
// Copied from https://github.com/sindresorhus/file-url/blob/14c7a69ae3798f50b3a4a21823c86e10b38160fe/readme.md
|
||||
|
||||
/// <reference path="file-url.d.ts" />
|
||||
|
||||
fileUrl('unicorn.jpg');
|
||||
//=> 'file:///Users/sindresorhus/dev/file-url/unicorn.jpg'
|
||||
|
||||
fileUrl('/Users/pony/pics/unicorn.jpg');
|
||||
//=> 'file:///Users/pony/pics/unicorn.jpg'
|
||||
Vendored
+16
@@ -0,0 +1,16 @@
|
||||
// Type definitions for file-url v1.0.1
|
||||
// Project: https://github.com/sindresorhus/file-url
|
||||
// Definitions by: MEDIA CHECK s.r.o. <http://www.mediacheck.cz/>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
/**
|
||||
* Convert a path to a file URL.
|
||||
*/
|
||||
declare function fileUrl(path:string):string;
|
||||
|
||||
/**
|
||||
* Convert a path to a file URL.
|
||||
*/
|
||||
declare module "file-url" {
|
||||
export = fileUrl;
|
||||
}
|
||||
Reference in New Issue
Block a user