---
title: "Discussion on \"Connecting Express backend to Javascript frontend\" | Hashnode"
description: "Discussion on \"Connecting Express backend to Javascript frontend\". This was something that confused me until recently.\nThe set up\nLet's say you have your server running on port 8000 with this code:\napp.get('/api', async (req, res) => {\n  // get some data from an API\n  console.log(data)\n  res.json(data)\n})\n\nIf you go..."
url: "https://hashnode.com/posts/connecting-express-backend-to-javascript-frontend/6175237c0c5e175a1c6174d7"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Connecting Express backend to Javascript frontend](https://blog.nicm42.me.uk/connecting-express-backend-to-javascript-frontend?utm_source=hashnode&utm_medium=feed)

This was something that confused me until recently. The set up Let's say you have your server running on port 8000 with this code: app.get('/api', async (req, res) => { // get some data from an API console.log(data) res.json(data) }) If you go...

Oct 24, 2021 · 2 min read · blog.nicm42.me.uk  
Read the article

-   [#javascript](https://hashnode.com/tag/javascript)

## Written by

[Nic](https://hashnode.com/@nicm42)

@nicm42 · England

  
[View profile](https://hashnode.com/@nicm42)

This week I learnt...

Front End Developer. I like problem solving and making things pretty. I also like red.

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
