maheshbasnet089 / tapShare

Tapshare is a simple, secure, and reliable file sharing platform that allows users to quickly and easily send large files over the internet. Whether you need to send files to friends and family, or share important documents with colleagues and clients, Tapshare provides a convenient and secure solution.
https://tapshare.xyz
GNU General Public License v3.0
52 stars 32 forks source link

add a loader too while fetching data (code/files) #50

Closed maheshbasnet089 closed 1 year ago

maheshbasnet089 commented 1 year ago

loader need while it is still being fetched in the code as well as file page too

arpan404 commented 1 year ago

Okay ☂︎

maheshbasnet089 commented 1 year ago

Loader is not being shown @arpan404 why is that or is it my device problem ?

maheshbasnet089 commented 1 year ago

@arpan404 did u implemented it in viewtext page only ? We need it in all page where there is fetching like tapshare.xyz/1234433

maheshbasnet089 commented 1 year ago

Screenshot_2023-07-10-17-52-42-030_com android chrome In these pages of code and file too

arpan404 commented 1 year ago

Ok

arpan404 commented 1 year ago

I suggest it to add at this page when it will be redesigned

arpan404 commented 1 year ago

I will rewrite that page within 2 days

arpan404 commented 1 year ago

@maheshbasnet089 a suggestion for you, don't import whole React while using builtin hooks like useState, useEffect and so on.

image

Don't do like this, it will hamper the performance and it's not a good code practice of React

maheshbasnet089 commented 1 year ago

okay @arpan404

maheshbasnet089 commented 1 year ago

I will rewrite that page within 2 days

Any updates @arpan404 ?

arpan404 commented 1 year ago

Currently, I am quite busy on something else. I will do this work when I got free time.

maheshbasnet089 commented 1 year ago

any updates @arpan404 ?

maheshbasnet089 commented 1 year ago

@arpan404 updates ?

arpan404 commented 1 year ago

working on it currently

Suzan-Dev commented 1 year ago

@maheshbasnet089 a suggestion for you, don't import whole React while using builtin hooks like useState, useEffect and so on. image Don't do like this, it will hamper the performance and it's not a good code practice of React

I dont think it hampers the performance.

arpan404 commented 1 year ago

If the application only uses the useState hook, importing the entire React object will include unnecessary code in your bundle, leading to a larger bundle size. So, to keep your bundle size small and improve performance, it's recommended to import only the specific hook you need.

Suzan-Dev commented 1 year ago

If the application only uses the useState hook, importing the entire React object will include unnecessary code in your bundle, leading to a larger bundle size. So, to keep your bundle size small and improve performance, it's recommended to import only the specific hook you need.

As my understanding, using it like React.useState or using useState after destructuring is similar. In both way, we are using useState only from react. Found this question in stackoverflow too. https://stackoverflow.com/questions/59025940/should-i-import-usestate-and-useeffect-or-is-it-ok-to-use-react-usestate-and-rea