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

Generates invalid ts file if a table has column named "default" #90

Open
msuntharesan opened this issue Apr 19, 2018 · 3 comments
Open

Comments

@msuntharesan
Copy link

msuntharesan commented Apr 19, 2018

Hello,
I noticed this on postgres.
Ex:

image

I think it should rename it to _default

@abenhamdine
Copy link
Contributor

Indeed, we should have a list of words allowed in SQL, but reserved in Typescript in order to rename them at generation.

You could have used var as a column name too 😉

@xiamx
Copy link
Contributor

xiamx commented Apr 20, 2018

You can modify https://github.com/SweetIQ/schemats/blob/master/src/typescript.ts#L11 and add "default" into the reserved words and make a pull request.

@abenhamdine
Copy link
Contributor

abenhamdine commented Apr 20, 2018

You can modify /src/typescript.ts@master#L11 and add "default" into the reserved words and make a pull request.

Oh nice, didn't know.

chaffeqa added a commit to chaffeqa/schemats that referenced this issue Apr 29, 2020
`object` especially since this its part of the [Activity Stream](https://www.w3.org/TR/activitystreams-core/#activities) spec.

refs SweetIQ#90
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants