christianalfoni / webpack-bin

A webpack code sandbox
http://www.webpackbin.com
MIT License
710 stars 75 forks source link

Import files from package #217

Open sergeysova opened 7 years ago

sergeysova commented 7 years ago

image

// main.js

import React from 'react';
import {render} from 'react-dom';
import HelloWorld from './HelloWorld.js';
import SyntheticInputEvent from 'react-dom/lib/SyntheticInputEvent'

render(<HelloWorld/>, document.querySelector('#app'));

In react boilerplate

christianalfoni commented 7 years ago

Webpackbin 2 is on its way. You will be able to import any files in that version.

https://webpackbin-test.firebaseapp.com/#/

https://www.youtube.com/watch?v=LWZHFcA9W6M

sergeysova commented 7 years ago

@christianalfoni webpackbin2 do not have boilerplates?

zinkkrysty commented 7 years ago

Hmm the test version does not seem to support importing files from subfolder

https://webpackbin-test.firebaseapp.com/bins/-Kfh4YZj0W8a-ym6qrIl

image

christianalfoni commented 7 years ago

@zinkkrysty Hm, let me update test version with latest versions. It might also be related to the material-ui package itself. Packages are put together so differently that Webpackbin might have not analyzed it correctly.... but it works on webpackbin.com?

Test is now updated to latest version