Security News
Bun 1.2 Released with 90% Node.js Compatibility and Built-in S3 Object Support
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
react-server-gulp-module-tagger
Advanced tools
A gulp plugin to replace tags with module information
A gulp plugin for tagging react-server logger instances with information about the module they're being used in.
To transpile your source for use with React Server, install gulp and the plugin
npm i -D gulp react-server-gulp-module-tagger
Then add the task to your gulpfile
const gulp = require('gulp');
const tagger = require('react-server-gulp-module-tagger');
gulp.task('compile', () => {
gulp.src('src')
.pipe(tagger())
.pipe(gulp.dest('dist'));
});
A compile task might also use Babel with the React Server Babel preset to transpile jsx and es 7 for the browser and the server
const gulp = require('gulp');
const babel = require('gulp-babel');
const tagger = require('react-server-gulp-module-tagger');
gulp.task('compile', () => {
gulp.src('src')
.pipe(tagger(
trim: 'src.'
))
.pipe(babel({ presets: ['react-server'] }))
.pipe(gulp.dest('dist'));
});
Given a getLogger
call,
adds the correct arguments to keep the server and the browser in sync.
For example, given a module in src/components/my-feature/foo.js
, and using the options
{ trim: 'src.', prefix: 'react-server.' }
let logger = require("react-server").logging.getLogger(__LOGGER__);
returns a logger instance that will have consistent coloring on the server and
the client, and that has a human-friendly, readable name that easily maps to
the file tree (in this example react-server.components.my-feature.foo
).
If you need more than one logger in your module, you can distinguish them with labels
var fooLogger = logging.getLogger(__LOGGER__({ label: "foo" }));
var barLogger = logging.getLogger(__LOGGER__({ label: "bar" }));
Two other tokens, __CHANNEL__
and __CACHE__
, are reserved for future use,
and will also be replaced with a module context.
v0.6.0 (2017-01-28)
Previously, routes marked explicitly as GET would also accept POST and other requests. After upgrading to v0.6.0, routes will only match the verbs they are marked to accept, which may break some existing use cases. We recommended auditing your non-GET routes as part of upgrading to 0.6.0
react-server-cli
, react-server
react-server-examples
, react-server-redux
, react-server-test-pages
react-server-cli
, react-server
babel-plugin-react-server
, babel-preset-react-server
, generator-react-server
, react-server-cli
, react-server-gulp-module-tagger
, react-server-module-tagger
, react-server
babel-plugin-react-server
react-server-cli
, react-server
generator-react-server
, react-server-cli
react-server
react-server-cli
react-server-test-pages
react-server-test-pages
, react-server-website
react-server-cli
FAQs
A gulp plugin to replace tags with module information
The npm package react-server-gulp-module-tagger receives a total of 6 weekly downloads. As such, react-server-gulp-module-tagger popularity was classified as not popular.
We found that react-server-gulp-module-tagger demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
Security News
Biden's executive order pushes for AI-driven cybersecurity, software supply chain transparency, and stronger protections for federal and open source systems.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.