mirror of https://github.com/lukechilds/docs.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
2.2 KiB
20 lines
2.2 KiB
'use strict';Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
var _phantom = require('./phantom');var _phantom2 = _interopRequireDefault(_phantom);function _interopRequireDefault(obj) {return obj && obj.__esModule ? obj : { default: obj };}
|
|
|
|
/**
|
|
* Returns a Promise of a new Phantom class instance
|
|
* @param args command args to pass to phantom process
|
|
* @param [config] configuration object
|
|
* @param [config.phantomPath] path to phantomjs executable
|
|
* @param [config.logger] object containing functions used for logging
|
|
* @param [config.logLevel] log level to apply on the logger (if unset or default)
|
|
* @returns {Promise}
|
|
*/
|
|
function create(args, config) {
|
|
return new Promise(resolve => resolve(new _phantom2.default(args, config)));
|
|
}exports.default =
|
|
|
|
{ create };
|
|
|
|
module.exports.create = create;
|