Skip to content

Commit 6bd2058

Browse files
author
Christian van der Leeden
authored
fix: esm help text and removed use strict (#545)
* docs: added help text for --esm option * chore: removed use strict since it is already part of ESM
1 parent 96a5a27 commit 6bd2058

File tree

10 files changed

+3
-18
lines changed

10 files changed

+3
-18
lines changed

help/generate.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@ in the <FOLDER>. Specify `.` to create files in the current working directory.
66

77
OPTS
88

9+
--esm
10+
use the ESM template
11+
912
--integrate
1013
overwrite it when the target directory is the current directory (.)
1114

templates/app-esm/app.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
'use strict'
2-
31
import path from 'path'
42
import AutoLoad from '@fastify/autoload'
53
import { fileURLToPath } from 'url'

templates/app-esm/plugins/sensible.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
'use strict'
2-
31
import fp from 'fastify-plugin'
42
import sensible from '@fastify/sensible'
53

templates/app-esm/plugins/support.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
'use strict'
2-
31
import fp from 'fastify-plugin'
42

53
// the use of fastify-plugin is required to be able

templates/app-esm/routes/example/index.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
'use strict'
2-
31
export default async function (fastify, opts) {
42
fastify.get('/', async function (request, reply) {
53
return 'this is an example'

templates/app-esm/routes/root.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
'use strict'
2-
31
export default async function (fastify, opts) {
42
fastify.get('/', async function (request, reply) {
53
return { root: true }

templates/app-esm/test/helper.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
'use strict'
2-
31
// This file contains code that we reuse
42
// between our tests.
53

templates/app-esm/test/plugins/support.test.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
'use strict'
2-
31
import { test } from 'tap'
42
import Fastify from 'fastify'
53
import Support from '../../plugins/support.js'

templates/app-esm/test/routes/example.test.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
'use strict'
2-
31
import { test } from 'tap'
42
import { build } from '../helper.js'
53

templates/app-esm/test/routes/root.test.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
'use strict'
2-
31
import { test } from 'tap'
42
import { build } from '../helper.js'
53

0 commit comments

Comments
 (0)