GithubHelp home page GithubHelp logo

node.net's Introduction

If you want a full suger coated awesome node.js/.Net integration library checkout edge written by Tomek

Creating a nodejs native .Net extension

This short writeup will guide you through creating a simple node.js addon

Before we begin

  1. Read this short description on how to build a simple nodejs addon on windows.
  2. Download node.js sources.
  3. Make sure you have Python 2.x installed (not 3.x).
  4. Build node sources by running `vcbuild.bat'.
  5. Verify that node.lib is located under the Debug/ directory.

Creating a .Net node addon

  1. Fire up VS2010 and create a new C++ Empty CLR project. new project
  2. Open the project properties (Click Alt+Enter while the project file is selected)
  3. Set the project type and extension project type should be dll and the extension should be .node new project
  4. Set the include directories as follows (replace paths with the local nodejs source path). new project
  5. Set the libraries directories as follows (replace paths with the local nodejs source path). new project
  6. Add a new CPP file and call it SOME_PREFIX_Addon.cpp. This file will hold the actual addon definitions and dll entry point.
  7. Open the property pages of the new CPP file you created.
  8. Change the "Common Language Runtime Support" option to No Common Language RunTime Support
    new project

What's next?

  • use the project provided here as an initial implementation.
  • take a look at the following html presentation. the ppt explains the different steps necessary to register a class with V8.
  • start rocking!

node.net's People

Contributors

saary avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.