Skip to content

Commit

Permalink
Refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
xdan committed Aug 31, 2021
1 parent d9c0b17 commit a5449ea
Show file tree
Hide file tree
Showing 9 changed files with 6,660 additions and 15,672 deletions.
3 changes: 2 additions & 1 deletion .eslintrc.js
Expand Up @@ -8,7 +8,7 @@
module.exports = {
root: true,
parser: '@typescript-eslint/parser',
plugins: ['@typescript-eslint', 'header'],
plugins: ['@typescript-eslint', 'header', 'eslint-plugin-tsdoc'],
extends: [
'eslint:recommended',
'plugin:prettier/recommended',
Expand All @@ -20,6 +20,7 @@ module.exports = {
node: true
},
rules: {
'tsdoc/syntax': 'warn',
strict: ['error', 'never'],
'no-with': 'error',
'no-caller': 'error',
Expand Down
14 changes: 14 additions & 0 deletions index.d.ts
Expand Up @@ -19,6 +19,20 @@ declare global {
component: Nullable<IComponent>;
}

interface CaretPosition {
offsetNode: Node;
offset: number;
}

interface Document {
caretPositionFromPoint?(x: number, y: number): CaretPosition;
caretRangeFromPoint(x: number, y: number): Range;
}

interface ShadowRoot {
getSelection(): ReturnType<Window['getSelection']>;
}

interface Function {
originalConstructor: Function;
}
Expand Down

0 comments on commit a5449ea

Please sign in to comment.