Skip to content

识别路径是否类似 '~/Development/OpenSource'。

License

Notifications You must be signed in to change notification settings

iyowei/is-tilde-path

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

isTildePath(path)

识别路径是否类似 ~/Development/OpenSource

使用

  • path,{ String },路径
import { log } from 'console';
import isTildePath from '@iyowei/is-tilde-path';

log(isTildePath('~/Development/OpenSource`')); // true
log(isTildePath('/Users/iyowei/Development/OpenSource`')); // false

安装

Node Version Badge esm

# Pnpm
pnpm add @iyowei/is-tilde-path

# yarn
yarn add @iyowei/is-tilde-path

# npm
npm add @iyowei/is-tilde-path

参与贡献

PRs Welcome

About

识别路径是否类似 '~/Development/OpenSource'。

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published