Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion src/MountRenderer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ import type {
MountRendererProps,
RSTNode,
} from 'enzyme';
import { VNode, h, createElement } from 'preact';
import type { VNode } from 'preact';
import { h, createElement } from 'preact';
import { act } from 'preact/test-utils';

import { render } from './compat.js';
Expand Down
4 changes: 2 additions & 2 deletions src/ShallowRenderer.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import {
import type {
ShallowRenderer as AbstractShallowRenderer,
RSTNode,
ShallowRenderOptions,
} from 'enzyme';
import { VNode } from 'preact';
import type { VNode } from 'preact';

import MountRenderer from './MountRenderer.js';
import {
Expand Down
3 changes: 2 additions & 1 deletion src/compat.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
* Preact.
*/

import { Component, Fragment, VNode } from 'preact';
import type { Component, VNode } from 'preact';
import { Fragment } from 'preact';

import {
getDOMNode,
Expand Down
2 changes: 1 addition & 1 deletion src/preact10-internals.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Component, VNode } from 'preact';
import type { Component, VNode } from 'preact';

/**
* This module provides access to internal properties of Preact 10 VNodes,
Expand Down
3 changes: 2 additions & 1 deletion src/preact10-rst.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
*/

import type { NodeType, RSTNode } from 'enzyme';
import { Component, Fragment, VNode } from 'preact';
import type { Component, VNode } from 'preact';
import { Fragment } from 'preact';

import { childElements } from './compat.js';
import {
Expand Down
3 changes: 2 additions & 1 deletion src/shallow-render-utils.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { ComponentFactory, Component, Fragment, VNode, options } from 'preact';
import type { ComponentFactory, Component, VNode } from 'preact';
import { Fragment, options } from 'preact';

import { childElements } from './compat.js';

Expand Down
2 changes: 1 addition & 1 deletion src/util.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import type { RSTNode } from 'enzyme';
import { VNode } from 'preact';
import type { VNode } from 'preact';

export function getType(obj: Object) {
if (obj == null) {
Expand Down
4 changes: 2 additions & 2 deletions test/Adapter_test.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { VNode } from 'preact';
import type { VNode } from 'preact';
import * as preact from 'preact';
import { assert } from 'chai';
import { RSTNode } from 'enzyme';
import type { RSTNode } from 'enzyme';

import Adapter from '../src/Adapter.js';
import MountRenderer from '../src/MountRenderer.js';
Expand Down
2 changes: 1 addition & 1 deletion test/MountRenderer_test.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { assert } from 'chai';
import { RSTNode } from 'enzyme';
import type { RSTNode } from 'enzyme';
import { Component } from 'preact';
import * as preact from 'preact';
import { useEffect, useLayoutEffect, useState } from 'preact/hooks';
Expand Down
5 changes: 3 additions & 2 deletions test/preact-rst-test.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
import { assert } from 'chai';
import { Component, Fragment, VNode } from 'preact';
import type { VNode } from 'preact';
import { Component, Fragment } from 'preact';
import * as preact from 'preact';
import { NodeType, RSTNode } from 'enzyme';
import type { NodeType, RSTNode } from 'enzyme';

import { getNode, rstNodeFromElement } from '../src/preact10-rst.js';
import { getType } from '../src/util.js';
Expand Down
3 changes: 2 additions & 1 deletion test/shallow-render-utils-test.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { Fragment, VNode, cloneElement } from 'preact';
import type { VNode } from 'preact';
import { Fragment, cloneElement } from 'preact';
import { assert } from 'chai';
import * as preact from 'preact';

Expand Down
2 changes: 1 addition & 1 deletion test/util-test.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { assert } from 'chai';
import { NodeType } from 'enzyme';
import type { NodeType } from 'enzyme';

import { getDisplayName } from '../src/util.js';

Expand Down