I am trying to follow the Getting started instructions on creating an Observable Framework project from the start but I am eventually doing something wrong. Not very experienced with the command line …
I installed Node.js and in the terminal I started with npm init @observablehq
but what I get is a series of prompts different to what are shown in the Framework user guide. In the end a package.json
file is created within the project folder.
PS C:\Users\Admin> mkdir ojs-fm-test
Directory: C:\Users\Admin
Mode LastWriteTime Length Name
---- ------------- ------ ----
d----- 2/16/2024 8:49 PM ojs-fm-test
PS C:\Users\Admin> cd .\ojs-fm-test\
PS C:\Users\Admin\ojs-fm-test> npm init @observablehq
This utility will walk you through creating a package.json file.
It only covers the most common items, and tries to guess sensible defaults.
See `npm help init` for definitive documentation on these fields
and exactly what they do.
Use `npm install <pkg>` afterwards to install a package and
save it as a dependency in the package.json file.
Press ^C at any time to quit.
package name: (ojs-fm-test)
version: (1.0.0)
description:
entry point: (index.js)
test command:
git repository:
keywords:
author:
license: (ISC)
About to write to C:\Users\Admin\ojs-fm-test\package.json:
{
"name": "ojs-fm-test",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "",
"license": "ISC"
}
Is this OK? (yes)
PS C:\Users\Admin\ojs-fm-test>
What am I doing wrong?