We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 2b62d6e + 22dceb4 commit 93e673cCopy full SHA for 93e673c
src/tabs.ts
@@ -207,7 +207,8 @@ export class Tabs extends Component<TabsOptions> {
207
this._index = Math.max(Array.from(this._tabLinks).indexOf(this._activeTabLink), 0);
208
if (this._activeTabLink && this._activeTabLink.hash) {
209
this._content = document.querySelector(this._activeTabLink.hash);
210
- this._content.classList.add('active');
+ if (this._content)
211
+ this._content.classList.add('active');
212
}
213
214
0 commit comments