Browse Source

remove react extenals

pull/8280/head
afc163 7 years ago
parent
commit
1e1baf01f6
  1. 5
      site/bisheng.config.js
  2. 7
      site/theme/static/template.html

5
site/bisheng.config.js

@ -74,11 +74,6 @@ module.exports = {
'create-react-class': 'preact-compat/lib/create-react-class',
'react-router': 'react-router',
});
} else if (isDev) {
config.externals = Object.assign({}, config.externals, {
react: 'React',
'react-dom': 'ReactDOM',
});
}
config.babel.plugins.push([

7
site/theme/static/template.html

@ -111,13 +111,6 @@
<div id="react-content">
{{ content | safe }}
</div>
{% if not usePreact %}
{% if isDev %}
<script src="https://as.alipayobjects.com/g/component/??react/15.6.1/react.js,react/15.6.1/react-dom.js"></script>
{% else %}
<script src="https://as.alipayobjects.com/g/component/??react/15.6.1/react.min.js,react/15.6.1/react-dom.min.js"></script>
{% endif %}
{% endif %}
<script src="{{ root }}common.js"></script>
<script src="{{ root }}index.js"></script>
</body>

Loading…
Cancel
Save