| name | javascript-style |
|---|---|
| description | JavaScript and TypeScript declaration style for lib, webpack, types — ESLint standard, modules, JSDoc. |
- Editing
lib/**/*.js,webpack/**/*.js,types/**, or root*.mjs. - Matching ESLint standard style and public JSDoc for npm consumers.
- Source is ES modules under
lib/(import/export). Builds target Node and browsers via Babel + Webpack (package.jsonscripts). types/holds public TypeScript declarations for npm; keep aligned withlib/JSDoc and exports.
- ESLint uses
eslint-config-standardand@babel/eslint-parser; match semicolon-free standard style and two-space indentation as in existinglib/files. - Environment: ESLint
es2020;test/**/*.jsmay relax rules viaoverridesin.eslintrc.js.
- Prefer named exports where the codebase already does; default exports for factories (
contentstackClient, HTTP client factory). - JSDoc (
@memberof,@func,@param,@returns,@example) on public API, consistent withlib/contentstack.jsandlib/contentstackClient.js. - Dependencies:
lodash,axios,qs,@contentstack/utils— follow existing import paths (including.jssuffixes where used).
- Avoid noisy
console.login library code except via existinglogHandler/ patterns inlib/core/contentstackHTTPClient.js. - Never log full authtoken, management tokens, or passwords.