diff --git a/.scaffdog/documents/modifier.md b/.scaffdog/documents/modifier.md index 9db14cd..6f07c35 100644 --- a/.scaffdog/documents/modifier.md +++ b/.scaffdog/documents/modifier.md @@ -7,8 +7,10 @@ output: "**/*" # [[inputs.name]].[[inputs.authoringFormat]] ```ts +[[name := camel(inputs.name)-]] + import { modifier } from "ember-modifier"; -export default modifier(function foo(element /*, positional, named*/) {}); +export default modifier(function [[name]](element /*, positional, named*/) {}); ``` diff --git a/.scaffdog/documents/service.md b/.scaffdog/documents/service.md index f86369e..b794062 100644 --- a/.scaffdog/documents/service.md +++ b/.scaffdog/documents/service.md @@ -11,11 +11,11 @@ output: "**/*" import Service from "@ember/service"; -export default class [[name]]Service extends Service {} +export default class [[name]] extends Service {} [[if inputs.authoringFormat == "ts"]] declare module "@ember/service" { interface Registry { - "[[inputs.name]]": [[name]]Service; + "[[inputs.name]]": [[name]]; } } [[end]] diff --git a/test/__snapshots__/generate-service.test.ts.snap b/test/__snapshots__/generate-service.test.ts.snap index 8f49281..17f29f4 100644 --- a/test/__snapshots__/generate-service.test.ts.snap +++ b/test/__snapshots__/generate-service.test.ts.snap @@ -3,25 +3,25 @@ exports[`generates a \`.js\` service 1`] = ` "import Service from "@ember/service"; -export default class FooService extends Service {} +export default class Foo extends Service {} " `; exports[`generates a \`.js\` service at a custom path 1`] = ` "import Service from "@ember/service"; -export default class FooService extends Service {} +export default class Foo extends Service {} " `; exports[`generates a \`.ts\` service 1`] = ` "import Service from "@ember/service"; -export default class FooService extends Service {} +export default class Foo extends Service {} declare module "@ember/service" { interface Registry { - "foo": FooService; + "foo": Foo; } } " @@ -30,11 +30,11 @@ declare module "@ember/service" { exports[`generates a \`.ts\` service at a custom path 1`] = ` "import Service from "@ember/service"; -export default class FooService extends Service {} +export default class Foo extends Service {} declare module "@ember/service" { interface Registry { - "foo": FooService; + "foo": Foo; } } "