🐊 Pluggable and configurable JavaScript Linter, code transformer and formatter with built-in ESLint and Babel support for js, jsx typescript, flow, markdown, yaml and json. Write declarative codemods in a simplest possible way 😏
MIT License
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago
Hi folks! I want to highlight some news about putout
. The time is came for a new major release 🎉 .
Let's talk about changes and abilities you will have with this.
Plugin apply-shorthand-properties has a lot fixes that not everywhere is applicable, for example:
-const socket1 = io.listen(server, {
+const socket = io.listen(server, {
path: `${prefix1}/socket.io`,
});
const socket2 = io.listen(server, {
path: `${prefix2}/socket.io`,
});
app.use(prefix1, cloudcmd({
+ socket
- socket: socket1,
}));
app.use(prefix2, cloudcmd({
socket: socket2,
}));
Such changes doesn't make code better, it deprives symmetry. Another example:
-const ONE_MINUTE = 60 * 1000;
+const reconnectionDeley = 60 * 1000;
const socket = io.connect(href + prefixSocket + '/config', {
reconnectionAttempts: Infinity,
- reconnectionDelay: ONE_MINUTE,
+ reconnectionDelay
path: prefix + '/socket.io',
});
Which was disabled for a long time in Cloud Commander with help of:
{
"match": {
"client/modules/config/index.js": {
"apply-shorthand-properties": [{
"ignore": [
"ONE_MINUTE"
]
}]
}
}
So apply-shorthand-properties
is removed from default installation after been disabled for some time,
Anyways it can be installed with:
npm i @putout/apply-shorthand-properties -D
It will be supported in the future, it's not deprecated, just decrease dependencies count a bit 📦 .
Did you know that putout
has built-int linters for:
css
markdown
json
yaml
You can configure a json
linter for code lintings inside markdown
file with:
{
"match": {
"*.md{json}": {
"putout-config": "on"
}
}
}
Here is how it works.
I want to mention that putout is used in such projects as:
User Menus
and before running it's converted to CommonJS
, and transformed with @putout/plugin-cloudcmd to new API
s so users have ability to avoid modification of their code :).Published by coderaiser over 3 years ago
Published by coderaiser over 3 years ago