File tree Expand file tree Collapse file tree 2 files changed +3
-6
lines changed Expand file tree Collapse file tree 2 files changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -130,9 +130,7 @@ def component_name
130130 def file_header
131131 if webpacker?
132132 if options [ :coffee ]
133- %|import React from 'react'\n |
134- %|import PropTypes from 'prop-types'\n |
135- %|export default |
133+ %|import React from 'react'\n import PropTypes from 'prop-types'\n |
136134 else
137135 %|var React = require("react")\n |
138136 end
Original file line number Diff line number Diff line change 11< %= file_header % >
2- class @ < %= component_name % > extends React .Component
2+ export default class @ < %= component_name % > extends React .Component
33< % if attributes .size > 0 -% >
44 @propTypes =
55< % attributes .each do | attribute| -% >
@@ -17,5 +17,4 @@ class @<%= component_name %> extends React.Component
1717< % else -% >
1818 ` < div / > `
1919< % end -% >
20-
21- < %= file_footer % >
20+ < %= file_footer % >
You can’t perform that action at this time.
0 commit comments