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

Speed up Patterns page #286

Open
2 tasks
sashasushko opened this issue Mar 5, 2019 · 9 comments
Open
2 tasks

Speed up Patterns page #286

sashasushko opened this issue Mar 5, 2019 · 9 comments

Comments

@sashasushko
Copy link
Contributor

sashasushko commented Mar 5, 2019

We have hidden page with all patterns in Moira. Look at /patterns.

There is no pagination in API. And will not be. But sometimes there is hundreds of items in list. React can't fast render them. Page slow down.

Need some defer rendering.

ToDo:

  • add patterns fake data to fake api based on json-server. To simplify development
  • add code for defer rendering

Attention

Need collaborate with assigned person for issue #287

@lazycipher
Copy link

I would like to work on this.

@sashasushko
Copy link
Contributor Author

Okay

@sashasushko sashasushko moved this from Available to Taken in Google Summer of Code Introductory Tasks Mar 5, 2019
@Vivekrajput20
Copy link

@lazycipher are you still working on it? I would like to work on the issue if you aren't.

@lazycipher
Copy link

Hi @Vivekrajput20,

Yes, I'm working on it and I'll send PR soon.

@sashasushko
Copy link
Contributor Author

sashasushko commented Mar 12, 2019

@lazycipher

Fake API based on JSON server. To add data you need edit db.json. Add in top level key patterns, value must be list: []. Like this:

{
  ...
  "patterns": {
    "list": [ ... ]
  }
}

Then add to list array few objects with data. Look at object structure in Domain/Pattern.js. You can do it manually or write some code for data generation

@lazycipher
Copy link

lazycipher commented Mar 18, 2019

Hey @sashasushko ,
I'm following the same but I get an error when I use "patterns" but data loads on the page when I use "pattern".

When I put "patterns" in db.json I get this -> Imgur
But when I put "pattern" and navigate to the patterns page, I get the data on the page.

Please have a look at my generated data JSON Data
If anything's wrong please tell me :)

@sashasushko
Copy link
Contributor Author

Yep. Use pattern. It's my mistake. I mixed up page URL and API URL

@Vivekrajput20
Copy link

How is it going @lazycipher ? Do you need any help?

@idoqo
Copy link
Contributor

idoqo commented Feb 18, 2020

Hi @sashasushko I'd love to work on this and have created a PR for the fake data here: #291

@sashasushko sashasushko moved this from Available to Taken in Google Summer of Code Introductory Tasks Feb 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

4 participants