Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(renderer): render multiple font sources #545

Merged
merged 2 commits into from Apr 4, 2018

Conversation

TxHawks
Copy link
Collaborator

@TxHawks TxHawks commented Mar 22, 2018

Description

The generateFontSource iterated over the list of files passed to renderer.renderFont,
and reduced it to a single string. Instead of adding each resulting string to the previous string,
is has overwritten it.

A byproduct of overwriting was that if more than one file was passed, it resulted in an invalid string source, since it started with a ,.

This pull request fixed the above bug and generateFontSource now accumulates instead of overwrite.

Versioning

Patch

fela

Checklist

Quality Assurance

You can also run yarn run check to run all 4 commands at once.

  • The code was formatted using Prettier (yarn run format)
  • The code has no linting errors (yarn run lint)
  • All tests are passing (yarn run test)
  • There are no flow-type errors (yarn run flow)

Changes

If one of the following checks doesn't make sense due to the type of PR, just check them.

  • Tests have been added/updated
  • Documentation has been added/updated
  • My changes have proper flow-types

@TxHawks
Copy link
Collaborator Author

TxHawks commented Mar 22, 2018

Not sure why tests are failing in travis. They pass locally

* Fix the renderFont method so that it correctly render the src key
when multiple files are passed.
* Add a test
* Fix faulty tests in fela-plugin-embedded
* Update all packages dependant on "fela" to the latest version
* Update CHANGELOG
Copy link
Owner

@robinweser robinweser left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks fine!

@TxHawks TxHawks merged commit 075e3c6 into robinweser:master Apr 4, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants