Giter Site home page Giter Site logo

arcticicestudio / styled-modern-normalize Goto Github PK

View Code? Open in Web Editor NEW
17.0 2.0 1.0 250 KB

modern-normalize.css for styled-components

Home Page: http://npm.im/styled-modern-normalize

License: MIT License

JavaScript 100.00%
styled components styled-components modern-normalize normalize normalize-css react reactjs css css-in-js

styled-modern-normalize's People

Contributors

arcticicestudio avatar azdanov avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

jagarinart

styled-modern-normalize's Issues

Update to latest version

There is a modern-normalize.css version 0.5.0. And styled-components version 4.1.1 for peer dependency.

Would a PR be welcome with a version bump?

Sync to modern-normalize 0.60

0.60 was released about 6 months ago. Could the next release of this package include that with updated peer dependency for styled-components v5?

Expose used fonts via public API

Exposing used fonts via public API allows to customize and add new fonts without loosing the default fonts and fallbacks. This will include sans-serif (default text) and monospace (<code> and <pre>) fonts.

Implementation Design

It will be implemented as Array<String> to allow to easily prepend new fonts using Array.unshift().

Initial implementation

Implement the initial API for the CSS definitions based on modern-normalize version 0.4.0.

API

The package should expose the following exports:

  • default export modernNormalize
  • MODERN_NORMALIZE_VERSION to provide the version string
  • both should be available as named exports

Update peer dependency

As v5 has been out for a bit now, the following error is raised during a package install as it's not meeting the condition.

warning " > [email protected]" has incorrect peer dependency "styled-components@^2.0.0 || ^3.2.6 || ^4.1.2".

Support for styled-components v4

Related to #4
Implemented by @azdanov in PR #5

styled-components v4 has recently been released. Details about new awesome features and performance boosts can be found in the blog post, the changelog and the migration guide.
There is now a new way to use global styles via the createGlobalStyle factory API function that returns a React.Component instead of injecting it directly like in v3 with injectGlobalStyle.

To support v4, instructions will be added to the documentation how to use it with this project. We won't change the currently exported interpolated styles to export a React component since this won't allows users to compose or override the styles and would force them to use the component as it is. It would also break the usage with v3 or lower. Users who like to use the new component-based approach can simply create a new styeled component with the new createGlobalStyle API and inject the styles imported from this library, allowing them to adjust and modify it to fit their needs.

babel-macro version?

When building a project with create-react-app(CRA), styled-components offers importing it via styled-components/macro which will seamlessly integrate with CRA's babel config without having to do anything like eject config to add your own babel config and plugin for styled-components.

I've been doing so fine, but when I brought in this package, it wasn't happy as it's importing the non-babel-macro version.

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.