Skip to content

An SQL Editor built using React.js and TailwindCSS as a Frontend Assignment for Atlan

License

Notifications You must be signed in to change notification settings

KG-1510/atlan-task-sql-editor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🚀 Online SQL Editor - Atlan Frontend Engineering Assignment

Crafted with by Kushagra Gupta

Built using:

View Demo on the Deployed Site 🚀

Click https://sql-editor-react.netlify.app to view the deployed site

Screenshot 2022-06-25 at 9 49 27 AM

👨‍💻 Features

✅ Users can get data of any of the predefined SQL queries either by using SQL Editor or Sidebar Menu.
✅ Users can sort data directly by clicking the Table Headers title.
✅ Users can search for a particular data among many records using the search bar.
✅ Users can download the output window table as CSV, with just a single click.

✍️ Predefined SQL Queries

  • select * from customers
  • select * from categories
  • select * from employees
  • select * from order_details
  • select * from shippers
  • select * from suppliers

⚙️ NPM Modules Used

  • "react-ace": "^10.1.0", - To make the code editor
  • "react-csv-to-table": "^0.0.4", - To show the output as a simple CSV table
  • "react-dom": "^18.2.0", - To interact with React's virtual DOM
  • "react-icons": "^4.4.0", - To have an icon library
  • "react-router-dom": "^6.3.0", - To implement routing features provided by React.js
  • "react-toastify": "^9.0.5", - To show the toast notifications for a success or error event
  • "react-csv": "^2.2.2", - To export the output window table as CSV

⏱ Page Load Time

The Webapp loads in about 0.4 s to 0.6s. This is calculated by using Google Lighthouse tool in Chromium based browsers. NOTE: The Lighthouse Audits scores are decreased because of preinstalled browser extensions that are non-removable in my system.

Screenshot 2022-06-25 at 1 39 20 AM

🪜 Steps I took to optimize the page load time

  • Used .webp assets instead of .png or .jpeg to minmizing loading time.
  • Used SVG icons wherever possible as they are lighter than image type icons.
  • Used PurgeCSS to tree-shake unused styles and optimize my final build size.
  • Used Lighthouse DevTools Extension to find the performance issues and fix them using their actionable suggestion.
  • Used netlify that has world-class CDN technology that reduces waiting time even further.

Available Scripts

In the project directory, you can run:

yarn start

Runs the app in the development mode.
Open http://localhost:3000 to view it in the browser.

The page will reload if you make edits.
You will also see any lint errors in the console.

yarn build

Builds the app for production to the build folder.
It correctly bundles React in production mode and optimizes the build for the best performance.

The build is minified and the filenames include the hashes.
Your app is ready to be deployed!

See the section about deployment for more information.

About

An SQL Editor built using React.js and TailwindCSS as a Frontend Assignment for Atlan

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published