---
title: "Discussion on \"Function Declaration vs Function Expression: What's the Difference?\" | Hashnode"
description: "Discussion on \"Function Declaration vs Function Expression: What's the Difference?\". Two ways to write functions in JavaScript — but they behave differently. Let's understand both, once and for all."
url: "https://hashnode.com/posts/function-declaration-vs-function-expression-what-s-the-difference/69b5a3c0210c74252f165b4d"
---

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

Discussion

# [Function Declaration vs Function Expression: What's the Difference?](https://omkargupta.hashnode.dev/function-declaration-vs-function-expression-what-s-the-difference?utm_source=hashnode&utm_medium=feed)

Two ways to write functions in JavaScript — but they behave differently. Let's understand both, once and for all.

Mar 14 · 9 min read · omkargupta.hashnode.dev  
Read the article

-   [#javascript](https://hashnode.com/tag/javascript)
-   [#hoisting](https://hashnode.com/tag/hoisting)
-   [#functions](https://hashnode.com/tag/functions)
-   [#js-tips](https://hashnode.com/tag/js-tips)
-   [#chaicode](https://hashnode.com/tag/chaicode)

## Written by

[Omkar Gupta](https://hashnode.com/@OmkarDevtsx)

@OmkarDevtsx

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

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
