Installed Eleventy, Made Index Page
These are the prelimiary setps to set up Eleventy.
- Created a folder for the website (I called mine "Website").
- Opened the Website folder in VS Code.
- Confirmed that Node.js was installed with
node -v(v22.14.0 was installed). - Made
.eleventy.jsconfiguration file. Added code similar to what is used in the Learn Eleventy project:
module.exports = (eleventyConfig) => {
return {
dir: {
input: 'src',
output: 'public',
},
};
};
- Made
/srcfolder. - In
/srcmadeindex.mdwith Hello World placeholder. - Added
package.jsonwithnom init -y. - In
package.json, replaced test script with"start": "npx eleventy --serve". - Installed Eleventy with
npm install @11ty/eleventy. - Ran Eleventy with
npm start. This creates/publc. Checked http://localhost:8080.