Skip to content

Conversation

@rschristian
Copy link
Member

Just minor revisions to docs, in ReadMe and CLI

@rschristian rschristian requested a review from a team as a code owner February 5, 2022 19:58
@changeset-bot
Copy link

changeset-bot bot commented Feb 5, 2022

🦋 Changeset detected

Latest commit: 92a2896

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
preact-cli Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

{
name: '--template',
description: 'Path to custom HTML template',
description: 'Path to custom HTML template (default "src/template.html")',
Copy link
Member Author

@rschristian rschristian Feb 5, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't set this as an actual default value in sade, only in the description, to keep this detection intact:

const inProjectTemplatePath = resolve(src, 'template.html');
let template = defaultTemplate;
if (existsSync(inProjectTemplatePath)) {
template = inProjectTemplatePath;
}
if (config.template) {
const templatePathFromArg = resolve(cwd, config.template);
if (existsSync(templatePathFromArg)) template = templatePathFromArg;
else {
warn(`Template not found at ${templatePathFromArg}`);
}
}

@ForsakenHarmony ForsakenHarmony merged commit 6af4e9d into master Feb 9, 2022
@ForsakenHarmony ForsakenHarmony deleted the chore/docs branch February 9, 2022 16:35
@preact-bot preact-bot mentioned this pull request Feb 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants