DZone
Thanks for visiting DZone today,
Edit Profile
  • Manage Email Subscriptions
  • How to Post to DZone
  • Article Submission Guidelines
Sign Out View Profile
  • Post an Article
  • Manage My Drafts
Over 2 million developers have joined DZone.
Log In / Join
Refcards Trend Reports
Events Video Library
Refcards
Trend Reports

Events

View Events Video Library

Related

  • 10 Go Best Practices Every Backend Developer Should Know
  • Kotlin Code Style: Best Practices for Former Java Developers
  • The Cypress Edge: Next-Level Testing Strategies for React Developers
  • Why You Don’t Need That New JavaScript Library

Trending

  • Ujorm3: A New Lightweight ORM for JavaBeans and Records
  • Multi-Scale Feature Learning in CNN and U-Net Architectures
  • Building an Image Classification Pipeline With Apache Camel and Deep Java Library (DJL)
  • End-to-End Event Streaming With Kafka, Spring Boot and AWS SQS/SNS (Production-Ready Code Guide)
  1. DZone
  2. Coding
  3. Languages
  4. Basic Frontend Dev Environment Setup

Basic Frontend Dev Environment Setup

By 
Jawad Hasan Shani user avatar
Jawad Hasan Shani
DZone Core CORE ·
May. 15, 20 · Code Snippet
Likes (3)
Comment
Save
Tweet
Share
11.4K Views

Join the DZone community and get the full member experience.

Join For Free

In this post, I will share with you a very basic development environment setup which is very useful if you just quickly want to evaluate some functionality. At the same time, can act as a good foundation and can be extended once you are done with the initial testing.

Angular and React are nowadays the default choice for frontend development, but for simple POC and validation purposes, we don't have to use those; this way, we can avoid complexity.

The idea is to keep it very simple and reuse this approach for other POC projects as well. However, if you want to see more details about specific topics e.g. Git, then you can find some posts written by me on those topics here on DZone or ask in comments. Ok, let's see the steps involved in this setup.

Steps

  • Create a git-repo for the project. Add ReadMe and .gitignore files.
  • Initialize npm >> npm init
  • Install lite-server>>npm install –save-dev lite-server
  • Add lite-server config file: bs-config.json and update npm-start script: lite-server.
  • Install some initial dependencies:
    • npm install  — save bootstrap
    • npm install — save jquery
    • npm install — save font-awesome
  • Create index.html (see example code)

The result of following these steps is that you will have a starting point to test your idea. Furthermore, you can clone the sample-code repository, and you have all above mentioned steps already done for you. So, one git-clone command and the whole environment is available. At this point, the environment is done, and the whole idea was to keep it very minimum for quick reuse.

Screenshot of Index.html

The HTML code is available in the repo, and here are the screenshots of that simple HTML structure. 

Head of HTML file

Body of HTML file

Other Screenshots

Here are some other screenshots, showing the folder structure and some code. Again, if you clone the repo, you have all this available to you. 

Screenshots of file structure

Summary

So, this setup can now be reused for POC type cases. Let me know if you have any comments in this regard. Until next time, Happy Coding.

References

  • https://github.com/jawadhasan/basic-frontend-starter
dev code style Npm (software) Font Awesome HTML POST (HTTP) Clone (Java method) Testing Dependency

Published at DZone with permission of Jawad Hasan Shani. See the original article here.

Opinions expressed by DZone contributors are their own.

Related

  • 10 Go Best Practices Every Backend Developer Should Know
  • Kotlin Code Style: Best Practices for Former Java Developers
  • The Cypress Edge: Next-Level Testing Strategies for React Developers
  • Why You Don’t Need That New JavaScript Library

Partner Resources

×

Comments

The likes didn't load as expected. Please refresh the page and try again.

  • RSS
  • X
  • Facebook

ABOUT US

  • About DZone
  • Support and feedback
  • Community research

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

  • Article Submission Guidelines
  • Become a Contributor
  • Core Program
  • Visit the Writers' Zone

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 3343 Perimeter Hill Drive
  • Suite 215
  • Nashville, TN 37211
  • [email protected]

Let's be friends:

  • RSS
  • X
  • Facebook