artiomtr / aqu Goto Github PK
View Code? Open in Web Editor NEWπ Powerful tool for easy typescript/javascript package development powered by esbuild and DTS bundle generator.
License: MIT License
π Powerful tool for easy typescript/javascript package development powered by esbuild and DTS bundle generator.
License: MIT License
Aqu should generate package with prepare script, which install husky hooks
Currently, aqu supports only npm. Maybe, aqu should support yarn, and even pnpm.
Aqu cli should have cli argument for not deleting build directories.
Aqu is not fully tested, so maybe before version 1.0.0 we should print a message with a link to github issues, for more extensive feedback collection
author
field in package.json
is set to undefined
when using yarn
as the package manager, even when user.name
is properly set in global git config.
Moreover, it will be nice to include the author's email address if it's set.
To reproduce, run aqu create
and select yarn
as the package manager.
Currently, there is no examples for templates. In folder example/templates
we should add example packages, which are created via aqu create
.
npm install
command throws error when package is created from react template
In order to build tree-shakable library we need to generate ESM modules format and preserve module structure from source folder (preserveModules option exists in Rollup). I have found that esbuild
do not have such option, so it possible to use rollup
only for esm
build when side effects optimization is enabled.
Build error when aqu is used with @vanilla-extract/esbuild-plugin
I digged around for a bit and I think this line is where it went wrong.
But when I use the same plugin for esbuild-only project, it worked just fine.
So I'm guessing the build.initialOptions
is not properly passed down?
Here's a reproducible repo.
Aqu should have functionality to eject configuration, for more flexible configuration.
Also, maybe we should add revert command, to delete ejected configuration and return to the initial behavior
Thanks for creating and sharing such a great work. Facing following problem and pls guide me on how to resolve it.
Problem:
Tried to create custom components out of @fluentui/react but getting following error in browser when consuming it in Tests. There is no error during the build times.
Verified the #1 and #2 issues mentioned in the "Error Details" using this reference and there is no version mismatch and duplicate copy.
Error Details:
Uncaught Error: Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:
Currently, aqu do not resolves symlinks, when searches files
Currently, aqu build
command supports only --config
flag. It would be nice if users could specify some build options via command line, like:
aqu build --input ./src/index.js --format=cjs --format=esm
Currently, usage gif in README weighs 24.1 mb. This gif needs optimization
Currently, aqu create
generates project without gitignore file
I'm trying to build my project with multiple entry points, so I use the "input" setting as array and i set "outdir" in my custom config file but ESBuild throws error: Must use "outdir" when there are multiple input files
.
Alternatively, i can generate multiple entry points using an array of config objects, but I guess that's not a desired behavior and in the other hand, since "outdir" is not used in esbuild config, if i want to solve it, i must define "outdir" in "buildOptions" object, but we have other problem, it throws error: Cannot use both "outfile" and "outdir"
and it doesn't matter if i set "outfile" as undefined, unknown, null or i don't set it, the error goin to be throw.
Keep in mind that, if i define "input" as array i desire that aqu set the "name" of the file as [name].production
, [name].development
and [name]
for the entry, and not [package_name].production
, [package_name].development
and [package_name]
becase each overwrite the last, it would great that Aqu do it by default.
My Settings file.
Context: I am creating an encryption and signature module that includes symmetric and asymmetric methodology and the document or message signature module.
// aqu.config.ts
export default {
name: '[name]',
input: [
'./src/index.ts',
'./src/asymmetric.ts',
'./src/symmetric.ts',
'./src/signer.ts',
'./src/types.ts',
'./src/utils.ts'
],
format: ['cjs', 'esm'], // will generate multiple outputs: one for cjs and one for esm
cjsMode: 'production', // will generate separate files for development and production
outdir: 'dist', // default output directory
declaration: 'bundle', // will bundle declarations using https://github.com/timocov/dts-bundle-generator
externalNodeModules: true, // automatically will mark all node_modules as external
tsconfig: 'tsconfig.json', // default path to tsconfig
incremental: true, // will build incrementally
buildOptions: {}, // custom esbuild options
watchOptions: {
// chokidar watch options
ignored: ['node_modules/**', 'dist/**', 'build/**', 'out/**'], // by default, will ignore those folders
followSymlinks: false, // will not follow symlinks
},
};
Currently, while aqu is not published, there is some places, where aqu is installed locally.
Remove it before initial version.
To help vscode detect typings in *.test.ts
files, package should contain @types/jest in dev dependencies
aqu: 0.2.1
node: 16.4.2
pnpm: 6.10.3
os: Pop!_OS (Ubuntu) 21.04
When I try and run aqu build
or aqu watch
, it pretty much instantly fails:
Compilation started.
β Bundling using esbuild[aqu] No binary for esbuild found
βERRORβ Command failed with exit code 1.
It looks like this is because it is only testing for esbuild.exe
. Is aqu compatible with OSs other than Windows?
If I look at where it's looking for (i.e. /node_modules/.pnpm/[email protected]_@[email protected]/node_modules/esbuild/esbuild.exe
) the esbuild
binary I have is in bin/esbuild
, not in the root directory of that package. If I change aqu to look for esbuild/bin/esbuild
it works (although my code won't compile and esbuild gets a deadlock, but that's probably not an issue with aqu).
A declarative, efficient, and flexible JavaScript library for building user interfaces.
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. πππ
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google β€οΈ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.