前提・実現したいこと
Windows10に、Puppeteerをインストールしたいです。
試したこと
Node.jsをインストール。システム環境で見るとバージョンは8.9.4。インストーラーでPathも自動設定。
https://github.com/GoogleChrome/puppeteerでzipをダウンロード。デスクトップに解凍。
発生している問題・エラーメッセージ
そもそも起動がわからない。
C:\Users\username\Desktop\puppeteer-master\の位置はこれでOK?
OKとして、
C:\Users\username\Desktop\puppeteer-master\examples\screenshot.jsを実行する方法が不明。
コマンドプロンプトで、
cd C:\Users\username\Desktop\puppeteer-master\examples C:\Users\username\Desktop\puppeteer-master\examples>screenshot.js
と実行すると、ストアアプリをダウンロードする画面になる。
npm screenshot.js
と実行すると、
Usage: npm <command> where <command> is one of: access, adduser, bin, bugs, c, cache, completion, config, ddp, dedupe, deprecate, dist-tag, docs, doctor, edit, explore, get, help, help-search, i, init, install, install-test, it, link, list, ln, login, logout, ls, outdated, owner, pack, ping, prefix, profile, prune, publish, rb, rebuild, repo, restart, root, run, run-script, s, se, search, set, shrinkwrap, star, stars, start, stop, t, team, test, token, tst, un, uninstall, unpublish, unstar, up, update, v, version, view, whoami npm <command> -h quick help on <command> npm -l display full usage info npm help <term> search for help on <term> npm help npm involved overview Specify configs in the ini-formatted file: C:\Users\username.npmrc or on the command line via: npm <command> --key value Config info can be viewed via: npm help config npm@5.6.0 C:\Program Files (x86)\nodejs\node_modules\npm
と表示。
システム環境で見るとバージョンは8.9.4だが、npm@5.6.0と出る。これはOKなのか?
Q1)C:\Users\username\Desktop\puppeteer-master\の位置はこれでOK?
Q2)C:\Users\username\Desktop\puppeteer-master\examples\screenshot.jsを実行する方法は?
node.js初めてです。アドバイスお願いします。
回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。