Skip to content

adrien-f/hypernova-net

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HypernovaNet

Sample project using Hypernova and ASP .NET Core to render server-side React components.

Running

docker-compose up

Example

Currently it uses a tag helper.

import * as React from "react";
import {renderReact} from "hypernova-react"

interface HelloWorldProps {
    from: string;
}

export class HelloWorldComponent extends React.Component<HelloWorldProps, {}> {
    render() {
        return <h1>Hello World, from {this.props.from}!</h1>
    }
}

export default renderReact('HelloWorld', HelloWorldComponent);
services.AddSingleton<IHypernovaClient>(new HypernovaClient(new HypernovaConfig
{
    Endpoint = "http://127.0.0.1:3000"
}));
<hypernova component="HelloWorld" data="@Model.HelloWorldData"/>

About

Sample application trying to render a React component with Airbnb's hypernova

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published