• Stars
    star
    288
  • Rank 143,145 (Top 3 %)
  • Language
    JavaScript
  • License
    MIT License
  • Created over 8 years ago
  • Updated over 6 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A starting point for building isomorphic React applications with ASP.NET Core, leveraging existing techniques.

react-aspnet-boilerplate

A starting point for building universal/isomorphic React applications with ASP.NET Core 1, leveraging existing front-end approaches. Uses the JavaScriptViewEngine.

Goals

  1. Minimize .NET's usage - It's only usage should be for building REST endpoints (WebApi) and providing the initial state (pure POCO). No razor syntax anywhere.
  2. Isomorphic/universal rendering
  3. Client and server should render using the same source files (javascript)
  4. Out-of-the-box login/register/manage functionality - Use the branch empty-template if you wish to have a vanilla React application.

This approach is great for front-end developers because it gives them complete control to build their app as they like. No .NET crutches (bundling/razor). No opinions. No gotchas. Just another typical React client-side application, but with the initial state provided by ASP.NET for each URL.

Getting started

The best way to get started with this project is to use the Yeoman generator.

npm install -g yo
npm install -g generator-react-aspnet-boilerplate

Then generate your new project:

yo react-aspnet-boilerplate

You can also generate a clean template (no authentication/account management) with another generator:

yo react-aspnet-boilerplate:empty-template

After you have your new project generated, let's run that app!

cd src/ReactBoilerplate
npm install
gulp
dotnet restore
# The following two lines are only for the 'master' branch, which has a database backend (user management).
# They are not needed when using 'empty-template'.
dotnet ef migrations add initial
dotnet ef database update
dotnet run

Some of the branches in this repo that are maintained:

  • master - This is the main branch. It has all the stuff required to get you started, including membership, external logins (OAuth) and account management. This is the default branch used with the Yeoman generator.
  • empty-template - This branch for people that want an empty template with the absolute minimum recommend boilerplate for any ASP.NET React application.

The interesting parts

  • client.js and server.js - The entry point for the client-side/server-side applications.
  • Html.js and App.js - These files essentially represent the "React" version of MVC Razor's "_Layout.cshtml".
  • Controllers - The endpoints for a each initial GET request, and each client-side network request.

What is next?

I will be adding features to this project as time goes on to help me get started with new React projects in .NET. So, expect some more things. I am also open to contributions or recommendations.

I took a lot of things from react-redux-universal-hot-example, but not everything. As time goes on, expect to see more of the same patterns/technologies/techniques copied over.

More Repositories

1

WindowsSDK7-Samples

Repository that has all the samples from the Windows 7 SDK, untouched
C++
329
star
2

twitter-dump

Dump data from Twitter's public API.
C#
118
star
3

JavaScriptViewEngine

An ASP.NET MVC ViewEngine for rendering markup in a JavaScript environment. Ideal for React and Angular server-side rendering.
C#
75
star
4

darch-recipes

My operating systems, using Darch.
Shell
73
star
5

vroomjs-core

Cross-platform VroomJs with the .NET Core runtime.
C#
53
star
6

statik

A simple library to help create static websites, for developers. Use this to compose larger static site generators (blogs/documentation/etc), or to power your blog/site as a one-off.
C#
50
star
7

iTunesMobileDevice-Hook

This is a dll that can replace the iTunesMobileDevice.dll, forwarding the requests to the real iTunesMobileDevice.dll, and inspect the parameters being sent.
C
31
star
8

WPFKeyboard

A virtual keyboard in WPF that uses the built in keyboard layouts of the operating system.
C
31
star
9

DirectShow.NET

This is a mirror (and possible extensions/forks) for the DirectShow.NET library located over at http://sourceforge.net/projects/directshownet/
C#
23
star
10

TwitterBootstrapjQueryValidate

Client side validation with support for the Twitter Bootstrap markup.
JavaScript
22
star
11

apt-tool

This tool is helpful to create rootfs for debian-based distributions with reproducable outputs.
C#
16
star
12

gitlab-page-server

A GitLab page server. Similar to the built-in page server, but with some additional features.
C#
11
star
13

nVLC

VLC wrappers for .NET (WPF/WindowsForms/etc), based on http://www.codeproject.com/Articles/109639/nVLC
C#
10
star
14

sharp-data-access

A .NET library for common database functionality (migrations, ambient connection/transactions)
C#
9
star
15

WPF-MediaKit

A git clone of https://wpfmediakit.codeplex.com/
C#
9
star
16

N2Bootstrap

NOT MAINTAINED! - An N2CMS implementation of Twitter Bootstrap
C#
9
star
17

resume

My personal resume. https://resume.pknopf.com/
SCSS
8
star
18

JetsonTX1Drivers

Clean files, downloaded directly from NVIDIA. That is all.
Python
8
star
19

MonoTouch.SimplePing

Xamarin bindings for the SimplePing class/helper for pinging CORRECTLY in Xamarin.iOS/MonoTouch.
C#
8
star
20

github-release-sync

A helper tool (written in Go) that helps synchronize a GitHub release's files with a local directory.
Go
7
star
21

raspberry-pi-camera-source

A yocto-based image that plays a video on loop on boot. This is great to use as a test "camera" for video processing/capturing development.
BitBake
6
star
22

markdown-translator

A library to help translating markdown files to other languages, using the PO/POT standard.
C#
5
star
23

meta-intel-media-stack

A meta layer for using the intel media stack (01org) on Intel CPUs
BitBake
5
star
24

bulwark

An implementation of GitHub's CODEOWNERS file, but for GitLab.
C#
5
star
25

ResponsiveLayoutWithIsotope

Using a mobile friendly responsive layout with the jquery plugin Isotope
JavaScript
5
star
26

qt-net-core

An experiment to getting .NET Core working in QML.
C++
5
star
27

AppleDevice.NET

A .net library for interacting with iOS devices, particularly through USB (discovery, port tunneling, etc).
C#
5
star
28

DCMTK-build

Build DCMTK for Visual Studio the easy way. Run this script to checkout, cmake, compile and install dcmtk and all of its components.
C
4
star
29

pauldotknopf.github.io

My personal blog: https://pknopf.com/
C#
4
star
30

iphone-plist-net

Automatically exported from code.google.com/p/iphone-plist-net
C#
4
star
31

qt-module-example

An example project/repo that uses Qt's module system for "QT += custom". Support for examples/tools/tests. This is the same pattern that Qt uses for all it's modules.
QMake
4
star
32

Pek.Markdig.HighlightJs

A Markdig plugin to highlight code, using the highlight.js library.
JavaScript
4
star
33

WPFAnimationEncoding

A library that will encode WPF animations into a h264 video.
HTML
3
star
34

JavaScriptViewEngine.Samples

Sample projects that use the JavaScriptViewEngine. https://github.com/pauldotknopf/JavaScriptViewEngine
HTML
3
star
35

meta-dotnet

.NET Core meta layer for Yocto.
BitBake
3
star
36

net-native-lib-loader

A .NET library to help locating native libraries, loading them, and getting symbols from them.
C#
3
star
37

AsyncStreamCopyCPP

A simple crossplatform c++ implementation of copying one stream to another asynchronously, typically for IO (netowork/file/usb/etc) access.
C++
3
star
38

apt-repo-builder

C#
2
star
39

apt-tool-example

C#
2
star
40

Taygeta

A mirror for https://taygeta.codeplex.com/
C++
2
star
41

binary-repos

The repository that stores my compiled packages for various distros (Arch/Void Linux).
2
star
42

blue-ribbon

HTML
2
star
43

CLICOMPerformanceTest

Getting some performance benchmarks of C++/CLI vs COM
C++
2
star
44

PortAudio

This is a mirror for the PortAudio repository
C
2
star
45

youtube-archiver

Archives channels for offline searching/viewing.
C#
2
star
46

MonoTouch.Aviary

MonoTouch bindings for the super-awesome Aviary iOS image editor.
Objective-C
2
star
47

sharp-jobs

A simple low-friction job processor.
C#
1
star
48

GDCL-MP4

The github repository for the GDCL mp4 muxer/demuxers located at http://www.gdcl.co.uk/downloads.htm
C++
1
star
49

MonoTouch.Appirater

MonoTouch/Xamarin bindings for the Appirater class/project.
C#
1
star
50

PushSourceFilter

IN DEVELOPMENT: DirectShow push source filters, for delivering samples into DirectShow from an external application.
C++
1
star
51

generator-react-aspnet-boilerplate

A yeoman generator for https://github.com/pauldotknopf/react-aspnet-boilerplate
JavaScript
1
star
52

meta-intel-msdk

BitBake
1
star
53

automounter

A golang daemon for detecting media and issuing leases for mount points.
Go
1
star
54

dotnet-buildary

A set of helper scripts/libraries to make it easier to build projects.
C#
1
star
55

Adept.Combres

A more usable dotless filter for Combres as well as some helper methods that make working with Combres via the API more friendly (making internals available).
JavaScript
1
star
56

darch-void-recipes

My recipes for Void Linux.
C
1
star
57

WPFToolkit

This is a migration of the official WPFToolkit for future changes (since codeplex project is dead).
C#
1
star
58

qt-3d-stereoscopic

[WIP] Qt/QML components for rendering 3d video.
C++
1
star
59

dotfiles

Configuration files for my Ubuntu/Darch setup.
Shell
1
star
60

DCMTK

This is the DCMTK repository.
C++
1
star
61

public-speaker

A web-server that allows users to interact with your Spotify queue to play music.
CSS
1
star
62

N2Bootstrap.Blog

A blog extension to N2Bootstrap
C#
1
star
63

MonoTouch.AQGridView

iOS/MonoTouch bindings for the AQGridView project.
C#
1
star
64

MonoTouch.MFSideMenu

A monotouch implementation of the https://github.com/mikefrederick/MFSideMenu control.
C#
1
star
65

goidevice

Golang bindings for the libimobiledevice library.
Go
1
star
66

sharp-read-write-lock

A dumb lib to help manage read/write locks.
C#
1
star
67

dcmtk-build-support-libraries

Scripts and releases of the support libraries, used by dcmtk.
Shell
1
star
68

omaha

Automatically exported from code.google.com/p/omaha
C++
1
star
69

rockchip-camera-source

A yocto-based image that plays a video on loop on boot. This is great to use as a test "camera" for video processing/capturing development.
1
star
70

SourceIndexingSharp

A library that manages indexing pdb files for various storage servers. The ultimate goal is to create source server support for git.
C#
1
star
71

sharpwildmatch

A C# port of git/rsync's wildmatch function for shell-like globbing.
C#
1
star