From 0f09c88bf60e94afc14060dc5f8a94ffaf386d45 Mon Sep 17 00:00:00 2001 From: gipo355 <91525512+gipo355@users.noreply.github.com> Date: Thu, 25 Jul 2024 16:53:34 +0200 Subject: [PATCH] feat: add task to generate publishable React library This commit introduces a new task in Taskfile.yml named 'gen-react-pub-lib'. This task is designed to generate a publishable React library with specific options such as bundler, directory, importPath, and more. This will help in streamlining the process of creating new React libraries in the project. --- Taskfile.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Taskfile.yml b/Taskfile.yml index 52aa4aa..d65cdb6 100644 --- a/Taskfile.yml +++ b/Taskfile.yml @@ -25,3 +25,11 @@ tasks: cmds: - nx g @nx/js:lib --importPath=@gipo355/{{.CLI_ARGS}} --publishable --directory=packages/{{.CLI_ARGS}} --js=true + gen-react-pub-lib: + desc: Generate a publishable React library + cmds: + - nx generate @nx/react:library --name={{.CLI_ARGS}} --bundler=rollup + --directory=packages/{{.CLI_ARGS}} --importPath=@gipo355/{{.CLI_ARGS}} + --pascalCaseFiles=true --projectNameAndRootFormat=as-provided + --publishable=true --setParserOptionsProject=true --style=scss + --unitTestRunner=vitest --no-interactive