Skip to content

Templates for typescript react application#192

Closed
Bolid1 wants to merge 3 commits into
api-platform:mainfrom
Bolid1:master
Closed

Templates for typescript react application#192
Bolid1 wants to merge 3 commits into
api-platform:mainfrom
Bolid1:master

Conversation

@Bolid1

@Bolid1 Bolid1 commented Dec 15, 2019

Copy link
Copy Markdown
Contributor
Q A
Bug fix? no
New feature? yes
BC breaks? no
Deprecations? no
Tickets fixes #89
License MIT
Doc PR -

I used react templates as base for typescript templates.

Comment thread src/generators.js
import NextGenerator from "./generators/NextGenerator";
import ReactGenerator from "./generators/ReactGenerator";
import ReactNativeGenerator from "./generators/ReactNativeGenerator";
import TypescriptInterfaceGenerator from "./generators/TypescriptInterfaceGenerator";

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Interfaces generator is useful in certain cases, possible to keep it?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yes, of course. I'll make changes soon

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Check it out 👍

@Bolid1 Bolid1 requested a review from soyuka December 17, 2019 18:08

@soyuka soyuka left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

lgtm, if someone that knows react here can take a look it'd be awesome

@dunglas

dunglas commented Feb 25, 2020

Copy link
Copy Markdown
Member

It would be nice if we could find a way to merge the code between the JS React, TypeScript React and TypeScript Next generators. It would simplify the maintenance. Maybe could we support only TypeScript for instance? WDYT? /cc @Gregcop1

@dunglas dunglas mentioned this pull request Feb 25, 2020
@versedi

versedi commented Aug 14, 2020

Copy link
Copy Markdown

@dunglas did you made any decision on merging the codebase for js/ts react/vue/next?

I'm currently writing implementation for case that will generate Vue.js + Vuex in Typescript and was wondering if I even should bother with PR if the whole base is going to be rewritten.

@dunglas

dunglas commented Aug 14, 2020

Copy link
Copy Markdown
Member

For now we'll keep the generators separated (it's easier to maintain). PR welcome!

In the end, I would like to be able to "generate" readable JS code from the TypeScript code, but I'm not sure if it is possible. Another option could be to deprecate vanilla JS generators at some point and only support TS (users could still remove type definitions if they don't want to use them).

Base automatically changed from master to main January 24, 2021 21:38
@alanpoulain

alanpoulain commented Aug 30, 2022

Copy link
Copy Markdown
Member

We will only use #193 to reduce the burden of maintenance.
Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Convert the React generators to TypeScript

5 participants