Split the session, gate optional parameters on the peer version, own the SMPP version in defs
This commit is contained in:
@@ -24,6 +24,29 @@ export default tseslint.config(
|
||||
'no-console': 'error',
|
||||
},
|
||||
},
|
||||
{
|
||||
files: ['src/**/*.ts'],
|
||||
rules: {
|
||||
complexity: ['error', 10],
|
||||
'max-lines': ['error', { max: 350, skipBlankLines: true, skipComments: true }],
|
||||
'max-lines-per-function': ['error', { max: 40, skipBlankLines: true, skipComments: true }],
|
||||
'max-params': ['error', 5],
|
||||
},
|
||||
},
|
||||
{
|
||||
// The spec tables are data: their length tracks the specification, not any complexity.
|
||||
files: ['src/defs/*.ts'],
|
||||
rules: { 'max-lines': 'off' },
|
||||
},
|
||||
{
|
||||
// The codec branches per wire type and per parameter; splitting it scatters the wire format
|
||||
// across files instead. These two keep the ceiling they have today.
|
||||
files: ['src/dlr.ts', 'src/pdu.ts'],
|
||||
rules: {
|
||||
complexity: ['error', 22],
|
||||
'max-lines-per-function': ['error', { max: 75, skipBlankLines: true, skipComments: true }],
|
||||
},
|
||||
},
|
||||
{
|
||||
// ESC (0x1B) is the GSM 03.38 escape character, so it belongs in these patterns.
|
||||
files: ['src/defs/encodings.ts'],
|
||||
|
||||
Reference in New Issue
Block a user