MCPcopy
hub / github.com/airbnb/javascript / wrapComponent

Function wrapComponent

packages/eslint-config-airbnb/test/test-react-order.js:28–36  ·  view source on GitHub ↗
(body)

Source from the content-addressed store, hash-verified

26}
27
28function wrapComponent(body) {
29 return `\
30import React from 'react';
31
32export default class MyComponent extends React.Component {
33/* eslint no-empty-function: 0, class-methods-use-this: 0 */
34${body}}
35`;
36}
37
38test('validate react methods order', (t) => {
39 t.test('make sure our eslintrc has React and JSX linting dependencies', (t) => {

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected