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

[WIP] JSX support #76

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

[WIP] JSX support #76

wants to merge 1 commit into from

Conversation

Jomik
Copy link
Member

@Jomik Jomik commented Jul 20, 2018

Fixes #75

Expose a jsxFactory function.
Requires the following compileOptions in tsconfig:

"compilerOptions": {
  "jsx": "react",
  "jsxFactory": "createElement"
}

as well as importing createElement from turbine.

Allow specifying output as a property of the component in JSX.

  <div>
    Counter {count}
    <button output={{ incrementClick: "click" }}>+</button>
    <button output={{ decrementClick: "click" }}>-</button>
  </div>

@Jomik Jomik self-assigned this Jul 20, 2018
@codecov
Copy link

codecov bot commented Jul 20, 2018

Codecov Report

Merging #76 into master will decrease coverage by 1.81%.
The diff coverage is 25%.

Impacted Files Coverage Δ
src/elements.ts 96.39% <ø> (ø) ⬆️
src/index.ts 100% <100%> (ø) ⬆️
src/jsx.ts 20% <20%> (ø)

@paldepind paldepind mentioned this pull request Jul 21, 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.

idea: JSX to Turbine
1 participant