Use Electron with Database file

I have to build an application for a small company. I want to use a boilerplate which uses Electron, React Redux... but there is no server in the company. They want me to save a file on their network drive which can be accessed through the Electron ...
more »

2017-06-18 19:06 (1) Answers

Editing immutable state items

I'm trying to update some immutable data. However, I am doing it incorrectly and it doesn't work. My understanding, is I need to pass it a unique it (eg the key) so it knows which item in state to update. But this may be wrong, and I would like to d...
more »

2017-06-18 13:06 (2) Answers

Zoom that follows mouse

I'm trying to create a React Component that zooms an image and the zoomed image follows the mouse. I've created a pen to show what I've done so far: React Zoom And here is the code: class ProductGallery extends React.Component { constructor (pro...
more »

2017-06-18 07:06 (0) Answers

Using Dygraph in React with redux?

I've been having a lot of trouble implementing Dygraph in React (I'm using redux): The Dygraph wrapper packages on NPM don't seem to work. Also I can't simply use: <div id="graph"></div>. I believe this is beca...
more »

2017-06-18 03:06 (1) Answers

Get image from server and preview it on client

So i'm trying to get an image from a server and previewing it on the client, i can retrieve the image for now, but i don't know how to preview it on a web page asynchronously. axios.get(link,{responseType:'stream'}).then(img=>{ // What i have to ...
more »

2017-06-18 03:06 (1) Answers

Reactjs local image not loading

I'm having an issue loading an image locally in my reactjs file. Any help would be awesome. Thanks Failed to compile ./src/components/pages/home.js Module not found: Can't resolve '../Assets/images/Thomas-overlay3.jpg' in 'C:\Users\tcmar\Documents\...
more »

2017-06-18 02:06 (1) Answers

Importing multiple files in react

I am using create-react-app for my react project. It has got webpack configured for importing images. I wish to import multiple images (say 10) from a images folder into a component. The easiest way of doing this would be to add multiple import state...
more »

2017-06-17 19:06 (1) Answers

Reactjs : Multiple Forms in tabs with validation

Tab structure which will have same component in both the tabs Component can add 2 fields at a time which are same whenever clicked on add Form validations should happen for each newly added form on click on the last form in last tab data from all the...
more »

2017-06-17 16:06 (0) Answers

how can i use if inline react jsx

I wanna use 'if' in react router for check user is login but i don't know about correct syntax: const RouteWithSubRoutes = (route) => ( <Route exact path={route.path} render={props => ( <route.component {...props} routes={route.r...
more »

2017-06-17 13:06 (2) Answers

react uploading file by curl

I'm new to web development. In my linux box, i have a server which can upload and check files through curl commands(rest api). such as curl -T filename http://localhost:9000/jobs I have a react webpage, which wants to do the same thing as command ...
more »

2017-06-16 22:06 (0) Answers

React Mount/Unmount event

I have my router like this <Route component={Home} exact path="/" /> <Route component={ChannelScreen} path="/channel/:channelId" /> Home and ChannelScreen component contain a Player component. So when I change the page, a new Player i...
more »

2017-06-16 21:06 (1) Answers

Is the ordering of props in JSX important?

If the o object contains a key/value pair of: foo: 'bar' can I depend on these outcomes?: // foo will be 'bar' <MyComponent foo='should not override' {...o} /> // foo will be 'overridden' <MyComponent {...o} foo='overridd...
more »

2017-06-16 16:06 (3) Answers