I had a rollup setup while using ts-nameof. and I could use ts-nameof like: `nameof<PageContainer>()` which would turn to `PageContainer` ```json { "ts-nameof": "^5.0.0", "@types/ts-nameof": "^4.2.1", "rollup": "^2.39.0", "ttypescript": "^1.5.12", } ``` ```js export default { input: "src/index.ts", output: [...], plugins: [ typescript({ typescript: ttypescript, clean: true, useTsconfigDeclarationDir: true, transformers: [() => ({ before: [ tsNameOf ], after: [ ] })], tsconfigOverride: { compilerOptions: { sourceMap: true, inlineSourceMap: true, plugins: [], } } }), ], }; ``` recently I changed to nx monorepo setup and I installed ```json { "@types/ts-nameof": "^4.2.1", "babel-plugin-ts-nameof": "^4.2.1" "ts-nameof": "^5.0.0" } ``` and .babelrc: ```json { "presets": ["@nrwl/react/babel"], "plugins": [ "babel-plugin-ts-nameof" ] } ``` I don't know why but global nameof wasn't avaiable so I added ts-nameof to types in tsconfig as following ```js { "extends": "./tsconfig.json", "compilerOptions": { "outDir": "../../../dist/out-tsc", "types": ["ts-nameof", "node"], "module": "ESNext", "target": "es2015" } } ``` and when I build the project I get: ``` Call expression must have one argument or type argument: nameof() ``` seems like a bug because in rollup it works. and if I select a method from interface it works fine but empty it doesn't `console.log(nameof<Provider>(x => x.Something))` prints `Something`
This issue appears to be discussing a feature request or bug report related to the repository. Based on the content, it seems to be resolved. The issue was opened by ericaskari and has received 2 comments.