tsc:allowUnreachableCode, eslint:no-unreachable, assert->assertDev

This commit is contained in:
Jamie Kyle 2022-09-15 12:17:15 -07:00 committed by GitHub
parent f627a05cf8
commit eb10aafd7c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
57 changed files with 213 additions and 176 deletions

View file

@ -4,7 +4,7 @@
import type { KeyboardEvent } from 'react';
import React, { useState } from 'react';
import classNames from 'classnames';
import { assert } from '../util/assert';
import { assertDev } from '../util/assert';
import { getClassNamesFor } from '../util/getClassNamesFor';
type Tab = {
@ -28,7 +28,7 @@ export function useTabs({
selectedTab: string;
tabsHeaderElement: JSX.Element;
} {
assert(tabs.length, 'Tabs needs more than 1 tab present');
assertDev(tabs.length, 'Tabs needs more than 1 tab present');
const getClassName = getClassNamesFor('Tabs', moduleClassName);