ReactDOMLegacyFloat-test.js — react Source File
Architecture documentation for ReactDOMLegacyFloat-test.js, a javascript file in the react codebase.
Entity Profile
Source Code
/**
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*
* @emails react-core
* @jest-environment ./scripts/jest/ReactDOMServerIntegrationEnvironment
*/
'use strict';
let React;
let ReactDOMFizzServer;
describe('ReactDOMFloat', () => {
beforeEach(() => {
jest.resetModules();
React = require('react');
ReactDOMFizzServer = require('react-dom/server');
});
// fixes #27177
it('does not hoist above the <html> tag', async () => {
const result = ReactDOMFizzServer.renderToString(
<html>
<head>
<script src="foo" />
<meta charSet="utf-8" />
<title>title</title>
</head>
</html>,
);
expect(result).toEqual(
'<html><head><meta charSet="utf-8"/>' +
'<title>title</title><script src="foo"></script></head>' +
'</html>',
);
});
});
Source
Frequently Asked Questions
What does ReactDOMLegacyFloat-test.js do?
ReactDOMLegacyFloat-test.js is a source file in the react codebase, written in javascript.
Where is ReactDOMLegacyFloat-test.js in the architecture?
ReactDOMLegacyFloat-test.js is located at packages/react-dom/src/__tests__/ReactDOMLegacyFloat-test.js (directory: packages/react-dom/src/__tests__).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free