Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Eleventy Dev Server - CLI and watch option

Open
#45 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
javascript
Domain
cli, tooling

Research direction

Start by comparing the CLI handling of --watch and --dir with the setServerOptions({ watch }) configuration described in the issue, then check the Eleventy Dev Server man page. Done means the supported behavior for watching an array of external globs is documented or implemented, with the CLI and configuration paths agreeing.

Written by the indexing model from the issue text.

Description

enhancement needs-votes

This is a clarification rather than an issue I guess

Testing Eleventy 2.0.0@beta and Eleventy Dev Server 1.0.0, particularly the watch option in conjunction with external NPM scripts for CSS and JS processing. Can I use the --watch flag with the CLI or is the --dir flag the intended method for now ?

Everything works smoothly by doing npx @11ty/eleventy --serve with a JS configuration and setServerOptions

eleventyConfig.setServerOptions({
  watch: ["./dist/assets/css/**/*.css", "./dist/assets/js/**/*.js"],
  port: 3000,
});

Things are working as well with the CLI using a global --dir=\"./dist/\" flag

In some contexts, it would be great to be able to use the --watch flag with an array of globs (to watch files that are not necessarily in a single folder). Is that possible now / could be implemented down the line ? Looked at the Eleventy Dev Server man page but didn't see a way to do it.

Dominant language
JavaScript
Stars
109
Forks
19
Avg merge
6d 3h
Merged PRs (30d)
2

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from 11ty/dev-server

All issues in 11ty/dev-server

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.