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

Feat: Added feature Export Visits to download the csv of Visits and Views #840

Merged
merged 6 commits into from
Oct 16, 2024

Conversation

aryany9
Copy link
Contributor

@aryany9 aryany9 commented Oct 12, 2024

close #786

This PR adds the Export functionality to download the Visits & Views counts in an csv file on "Export Visits" button click.

Describe your changes

I have added an API to fetch the Views and Visits as per the document id and provide the JSON response in return.
image

Based on the Response, I am creating the CSV blob and downloading it on button click.
image

Checklist before requesting a review

  • I have performed a self-review of my code
  • If it is a core feature, I have added thorough tests.
  • I have added quick video solution as requested below.
20241012_214432357.mp4

@aryany9 aryany9 requested a review from mfts as a code owner October 12, 2024 16:20
Copy link

vercel bot commented Oct 12, 2024

@aryany9 is attempting to deploy a commit to the mftsio Team on Vercel.

A member of the Team first needs to authorize it.

Copy link

github-actions bot commented Oct 12, 2024

All contributors have signed the CLA ✍️ ✅
Posted by the CLA Assistant Lite bot.

@aryany9
Copy link
Contributor Author

aryany9 commented Oct 12, 2024

I have read the CLA Document and I hereby sign the CLA

@aryany9
Copy link
Contributor Author

aryany9 commented Oct 12, 2024

recheck

@aryany9 aryany9 changed the title [FEATURE] Added feature Export Visits to download the csv of Visits and Views [🕹️] [FEATURE] Added feature Export Visits to download the csv of Visits and Views Oct 12, 2024
@aryany9 aryany9 marked this pull request as draft October 12, 2024 18:23
@aryany9 aryany9 marked this pull request as ready for review October 12, 2024 18:25
@aryany9 aryany9 changed the title [🕹️] [FEATURE] Added feature Export Visits to download the csv of Visits and Views Feat: Added feature Export Visits to download the csv of Visits and Views Oct 12, 2024
@aryany9
Copy link
Contributor Author

aryany9 commented Oct 13, 2024

@mfts Please attach the oss.gg labels as well. They were not assigned by the bot.

Copy link
Owner

@mfts mfts left a comment

Choose a reason for hiding this comment

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

@aryany9 the package you used is abandoned! please make sure you review packages before adding anything external.

please change the approach to do it without an external library.
for example, something like this: https://dev.to/graciesharma/implementing-csv-data-export-in-react-without-external-libraries-3030

package.json Outdated Show resolved Hide resolved
@aryany9
Copy link
Contributor Author

aryany9 commented Oct 15, 2024

Hi @mfts, Thankyou for pointing out the abandoned package. It has been removed and the approach has been changed as well. I have tested it with the new approach it is working as expected. Do let me know if you require any more changes. Thankyou.

@aryany9 aryany9 requested a review from mfts October 15, 2024 10:28
Copy link
Owner

@mfts mfts left a comment

Choose a reason for hiding this comment

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

Looks amazing! Thanks so much for following the request and making it native without an external parser :)

Copy link

vercel bot commented Oct 16, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
papermark ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 16, 2024 5:37am

@mfts mfts merged commit 6739d2c into mfts:main Oct 16, 2024
3 checks passed
Copy link

oss-gg bot commented Oct 16, 2024

Awarding aryany9: 750 points 🕹️ Well done! Check out your new contribution on oss.gg/aryany9

@github-actions github-actions bot locked and limited conversation to collaborators Oct 16, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[🕹️] Export document views to CSV
2 participants