Skip to content

Commit

Permalink
Fixes next dev and adds the css requires
Browse files Browse the repository at this point in the history
  • Loading branch information
impronunciable committed Oct 6, 2016
1 parent 88b01e0 commit 1833eff
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
2 changes: 1 addition & 1 deletion bin/next-dev
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 3,7 @@
import { resolve } from 'path'
import parseArgs from 'minimist'
import Server from '../server'
import build from '../server/build'
import build from '../server/build/index'

const argv = parseArgs(process.argv.slice(2), {
alias: {
Expand Down
4 changes: 3 additions & 1 deletion client/eval-script.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 2,14 @@ import React from 'react'
import ReactDOM from 'react-dom'
import App from '../lib/app'
import Link from '../lib/link'
import Css from '../lib/css'

const modules = new Map([
['react', React],
['react-dom', ReactDOM],
['next/app', App],
['next/link', Link]
['next/link', Link],
['next/css', Css]
])

/**
Expand Down
3 changes: 2 additions & 1 deletion server/build/bundle.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 14,8 @@ export default function bundle (src, dst) {
'react-dom',
{
[require.resolve('react')]: 'react',
[require.resolve('../lib/link')]: 'next/link'
[require.resolve('../../lib/link')]: 'next/link',
[require.resolve('../../lib/css')]: 'next/css'
}
],
resolveLoader: {
Expand Down
3 changes: 2 additions & 1 deletion server/build/transpile.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 25,8 @@ const babelOptions = {
[
{ src: `npm:${babelRuntimePath}`, expose: 'babel-runtime' },
{ src: `npm:${require.resolve('react')}`, expose: 'react' },
{ src: `npm:${require.resolve('../lib/link')}`, expose: 'next/link' }
{ src: `npm:${require.resolve('../../lib/link')}`, expose: 'next/link' },
{ src: `npm:${require.resolve('../../lib/css')}`, expose: 'next/css' }
]
]
],
Expand Down

0 comments on commit 1833eff

Please sign in to comment.