feat(client): ts-migrate /client/src/html.js (#42468)
* rename * migrate Co-authored-by: Parth Parth <thecodingaviator@users.noreply.github.com>
This commit is contained in:
committed by
Mrugesh Mohapatra
parent
4b44bb37d9
commit
383320095f
@@ -1,8 +1,16 @@
|
|||||||
import React from 'react';
|
import React from 'react';
|
||||||
import PropTypes from 'prop-types';
|
|
||||||
|
|
||||||
export default class HTML extends React.Component {
|
interface HTMLProps {
|
||||||
render() {
|
body: string;
|
||||||
|
bodyAttributes?: Record<string, unknown>;
|
||||||
|
headComponents?: React.ReactNode[];
|
||||||
|
htmlAttributes?: Record<string, unknown>;
|
||||||
|
postBodyComponents?: React.ReactNode[];
|
||||||
|
preBodyComponents?: React.ReactNode[];
|
||||||
|
}
|
||||||
|
|
||||||
|
export default class HTML extends React.Component<HTMLProps> {
|
||||||
|
render(): JSX.Element {
|
||||||
return (
|
return (
|
||||||
<html id='__fcc-html' {...this.props.htmlAttributes} lang='en'>
|
<html id='__fcc-html' {...this.props.htmlAttributes} lang='en'>
|
||||||
<head>
|
<head>
|
||||||
@@ -28,12 +36,3 @@ export default class HTML extends React.Component {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
HTML.propTypes = {
|
|
||||||
body: PropTypes.string,
|
|
||||||
bodyAttributes: PropTypes.object,
|
|
||||||
headComponents: PropTypes.array,
|
|
||||||
htmlAttributes: PropTypes.object,
|
|
||||||
postBodyComponents: PropTypes.array,
|
|
||||||
preBodyComponents: PropTypes.array
|
|
||||||
};
|
|
Reference in New Issue
Block a user