sonarjs/strict-transport-security
eslint-plugin-sonarjs
No autofixRecommended
eslint.config.js
export default [
{
rules: {
"sonarjs/strict-transport-security": "error",
},
},
];HTTP Strict-Transport-Security policy should not be disabled
The documentation shows no incorrect example for this rule.
const express = require('express');
const helmet = require('helmet');
let app = express();
app.use(helmet.hsts({
maxAge: 31536000,
includeSubDomains: true
})); // CompliantExamples from the ESLint documentation.
sonarjs/strict-transport-security
eslint-plugin-sonarjs
export default [
{
rules: {
"sonarjs/strict-transport-security": "error",
},
},
];Oxlint does not have this rule.
Biome does not have this rule.
Regular expressions with the global flag should be used with caution
Regular expressions should not cause non-linear backtracking
Synchronous exception assertions should receive synchronous callbacks
Tests should not be registered asynchronously in suite callbacks