1
0
Fork 0
mirror of https://github.com/terribleplan/next.js.git synced 2024-01-19 02:48:18 +00:00
next.js/lib/css.js
Arunoda Susiripala 565bb5790b Update url.pushTo and url.replaceTo update only on dev. (#434)
In order to warn the user, now we are using a warn function
which is located in the lib/utils module.
2016-12-19 13:04:38 -08:00

24 lines
526 B
JavaScript

import { warn } from './utils'
const css = require('glamor')
warn('Warning: \'next/css\' is deprecated. Please use styled-jsx syntax instead.')
/**
* Expose style as default and the whole object as properties
* so it can be used as follows:
*
* import css, { merge } from 'next/css'
* css({ color: 'red' })
* merge({ color: 'green' })
* css.merge({ color: 'blue' })
*/
css.default = css.style
Object.keys(css).forEach(key => {
if (key !== 'default') {
css.default[key] = css[key]
}
})
module.exports = css