mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-31 17:38:48 +00:00
react app
This commit is contained in:
21
react-app/node_modules/path-exists/index.js
generated
vendored
Normal file
21
react-app/node_modules/path-exists/index.js
generated
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
'use strict';
|
||||
var fs = require('fs')
|
||||
|
||||
module.exports = function (pth, cb) {
|
||||
var fn = typeof fs.access === 'function' ? fs.access : fs.stat;
|
||||
|
||||
fn(pth, function (err) {
|
||||
cb(null, !err);
|
||||
});
|
||||
};
|
||||
|
||||
module.exports.sync = function (pth) {
|
||||
var fn = typeof fs.accessSync === 'function' ? fs.accessSync : fs.statSync;
|
||||
|
||||
try {
|
||||
fn(pth);
|
||||
return true;
|
||||
} catch (err) {
|
||||
return false;
|
||||
}
|
||||
};
|
21
react-app/node_modules/path-exists/license
generated
vendored
Normal file
21
react-app/node_modules/path-exists/license
generated
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com)
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in
|
||||
all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
THE SOFTWARE.
|
93
react-app/node_modules/path-exists/package.json
generated
vendored
Normal file
93
react-app/node_modules/path-exists/package.json
generated
vendored
Normal file
@@ -0,0 +1,93 @@
|
||||
{
|
||||
"_args": [
|
||||
[
|
||||
"path-exists@^1.0.0",
|
||||
"/Users/mromano/dev/react-sfs/node_modules/babel-core"
|
||||
]
|
||||
],
|
||||
"_from": "path-exists@>=1.0.0 <2.0.0",
|
||||
"_id": "path-exists@1.0.0",
|
||||
"_inCache": true,
|
||||
"_installable": true,
|
||||
"_location": "/path-exists",
|
||||
"_nodeVersion": "0.12.2",
|
||||
"_npmUser": {
|
||||
"email": "sindresorhus@gmail.com",
|
||||
"name": "sindresorhus"
|
||||
},
|
||||
"_npmVersion": "2.7.4",
|
||||
"_phantomChildren": {},
|
||||
"_requested": {
|
||||
"name": "path-exists",
|
||||
"raw": "path-exists@^1.0.0",
|
||||
"rawSpec": "^1.0.0",
|
||||
"scope": null,
|
||||
"spec": ">=1.0.0 <2.0.0",
|
||||
"type": "range"
|
||||
},
|
||||
"_requiredBy": [
|
||||
"/babel-core",
|
||||
"/babel-register"
|
||||
],
|
||||
"_resolved": "https://registry.npmjs.org/path-exists/-/path-exists-1.0.0.tgz",
|
||||
"_shasum": "d5a8998eb71ef37a74c34eb0d9eba6e878eea081",
|
||||
"_shrinkwrap": null,
|
||||
"_spec": "path-exists@^1.0.0",
|
||||
"_where": "/Users/mromano/dev/react-sfs/node_modules/babel-core",
|
||||
"author": {
|
||||
"email": "sindresorhus@gmail.com",
|
||||
"name": "Sindre Sorhus",
|
||||
"url": "sindresorhus.com"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/sindresorhus/path-exists/issues"
|
||||
},
|
||||
"dependencies": {},
|
||||
"description": "Check if a path exists",
|
||||
"devDependencies": {
|
||||
"ava": "0.0.4"
|
||||
},
|
||||
"directories": {},
|
||||
"dist": {
|
||||
"shasum": "d5a8998eb71ef37a74c34eb0d9eba6e878eea081",
|
||||
"tarball": "https://registry.npmjs.org/path-exists/-/path-exists-1.0.0.tgz"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=0.10.0"
|
||||
},
|
||||
"files": [
|
||||
"index.js"
|
||||
],
|
||||
"gitHead": "be563ef9f750ec4fcbd5cc77603c869bdee05658",
|
||||
"homepage": "https://github.com/sindresorhus/path-exists",
|
||||
"keywords": [
|
||||
"path",
|
||||
"exists",
|
||||
"exist",
|
||||
"file",
|
||||
"filepath",
|
||||
"fs",
|
||||
"filesystem",
|
||||
"file-system",
|
||||
"access",
|
||||
"stat"
|
||||
],
|
||||
"license": "MIT",
|
||||
"maintainers": [
|
||||
{
|
||||
"email": "sindresorhus@gmail.com",
|
||||
"name": "sindresorhus"
|
||||
}
|
||||
],
|
||||
"name": "path-exists",
|
||||
"optionalDependencies": {},
|
||||
"readme": "ERROR: No README data found!",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/sindresorhus/path-exists.git"
|
||||
},
|
||||
"scripts": {
|
||||
"test": "node test.js"
|
||||
},
|
||||
"version": "1.0.0"
|
||||
}
|
60
react-app/node_modules/path-exists/readme.md
generated
vendored
Normal file
60
react-app/node_modules/path-exists/readme.md
generated
vendored
Normal file
@@ -0,0 +1,60 @@
|
||||
# path-exists [](https://travis-ci.org/sindresorhus/path-exists)
|
||||
|
||||
> Check if a path exists
|
||||
|
||||
Because [`fs.exists()`](https://nodejs.org/api/fs.html#fs_fs_exists_path_callback) is being [deprecated](https://github.com/iojs/io.js/issues/103), but there's still a genuine use-case of being able to check if a path exists for other purposes than doing IO with it.
|
||||
|
||||
Never use this before handling a file though:
|
||||
|
||||
> In particular, checking if a file exists before opening it is an anti-pattern that leaves you vulnerable to race conditions: another process may remove the file between the calls to `fs.exists()` and `fs.open()`. Just open the file and handle the error when it's not there.
|
||||
|
||||
|
||||
## Install
|
||||
|
||||
```
|
||||
$ npm install --save path-exists
|
||||
```
|
||||
|
||||
|
||||
## Usage
|
||||
|
||||
```js
|
||||
// foo.js
|
||||
var pathExists = require('path-exists');
|
||||
|
||||
pathExists.sync('foo.js');
|
||||
//=> true
|
||||
```
|
||||
|
||||
|
||||
## API
|
||||
|
||||
### pathExists(path, callback)
|
||||
|
||||
#### path
|
||||
|
||||
*Required*
|
||||
Type: `string`
|
||||
|
||||
#### callback(error, exists)
|
||||
|
||||
*Required*
|
||||
Type: `function`
|
||||
|
||||
##### exists
|
||||
|
||||
Type: `boolean`
|
||||
|
||||
### pathExists.sync(path)
|
||||
|
||||
Returns a boolean of whether the path exists.
|
||||
|
||||
#### path
|
||||
|
||||
*Required*
|
||||
Type: `string`
|
||||
|
||||
|
||||
## License
|
||||
|
||||
MIT © [Sindre Sorhus](http://sindresorhus.com)
|
Reference in New Issue
Block a user