Commit Graph

9 Commits

Author SHA1 Message Date
Daniel P
b91704e3ca fix typos is multiple files (#728) 2018-10-15 12:29:51 +05:30
Rishichandra Wawhal
68c5f8ca85 firebase2graphql: add realtime section in readme (#674) 2018-10-08 15:25:28 +05:30
Rishichandra Wawhal
fbd220621d firebase2graphql: improve readme structure, update git and add more tests (#666) 2018-10-08 11:42:42 +05:30
Arpit Kushwaha
8454e70614 add some color to hearts (#656)
fill some colours in those colourless hearts
2018-10-05 23:46:29 +05:30
Rishichandra Wawhal
30273d354d improve normalization for firebase2graphql (#621) 2018-10-04 09:09:42 +05:30
Rishichandra Wawhal
0cf981ddf8 update firebase2graphql readme (#575) 2018-09-28 18:19:05 +05:30
Rishichandra Wawhal
bdb73fe6d1 add firebase2graphql to community tools (#573) 2018-09-28 17:45:22 +05:30
Rishichandra Wawhal
3d6732b678 change table and foreign-key naming conventions in json2graphql (#485)
Foreign keys will now be detected if a column name is `<table_name>_id`.

Earlier, foreign keys would be detected when column name was `<table_name - s>_id`. This was a problem because it placed restrictions on table names. Such restrictions were limiting us from importing complicated JSON databases.

Here are the examples of JSON sampel data for a user, post and comment schema as per new and old conventions:

Old convention:

```
{
    posts: [
        { id: 1, title: "Lorem Ipsum", views: 254, user_id: 123 },
        { id: 2, title: "Sic Dolor amet", views: 65, user_id: 456 },
    ],
    users: [
        { id: 123, name: "John Doe" },
        { id: 456, name: "Jane Doe" }
    ],
    comments: [
        { id: 987, post_id: 1, body: "Consectetur adipiscing elit" },
        { id: 995, post_id: 1, body: "Nam molestie pellentesque dui" }
    ]
}
```

New convention:

```
{
    post: [
        { id: 1, title: "Lorem Ipsum", views: 254, user_id: 123 },
        { id: 2, title: "Sic Dolor amet", views: 65, user_id: 456 },
    ],
    user: [
        { id: 123, name: "John Doe" },
        { id: 456, name: "Jane Doe" }
    ],
    comment: [
        { id: 987, post_id: 1, body: "Consectetur adipiscing elit" },
        { id: 995, post_id: 1, body: "Nam molestie pellentesque dui" }
    ]
};
``` 

@FrediBach I am not sure how this would affect [Blowson](https://github.com/FrediBach/json-data-extender). Can you provide some input?
2018-09-19 14:18:52 +05:30
Rishichandra Wawhal
68a2e0372f add json2graphql to community tools (#454) 2018-09-17 18:23:23 +05:30