Skip to content

Instantly share code, notes, and snippets.

@devStepsize
Last active April 22, 2016 21:18
Show Gist options
  • Select an option

  • Save devStepsize/8321bb4dfeb89f98daeb6347fea78cd6 to your computer and use it in GitHub Desktop.

Select an option

Save devStepsize/8321bb4dfeb89f98daeb6347fea78cd6 to your computer and use it in GitHub Desktop.
An example of the recieving end for messages from the main process.
<!-- index.html -->
<html>
<body>
<script>
require('electron').ipcRenderer.on('ping', function(event, message) {
console.log(message); // Prints "whoooooooh!"
});
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment