---
title: "Discussion on \"Conditional wrapping in React\" | Hashnode"
description: "Discussion on \"Conditional wrapping in React\". This is something you do not always need, but I wrote this article for those looking for it.\nSometimes we might have a generic element, a specific component that renders inside a modal.\nWhen a specific flag is set, the component should get a parent w..."
url: "https://hashnode.com/posts/conditional-wrapping-in-react/639570a4f31b409c5b358972"
---

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

Discussion

# [Conditional wrapping in React](https://h.daily-dev-tips.com/conditional-wrapping-in-react?utm_source=hashnode&utm_medium=feed)

This is something you do not always need, but I wrote this article for those looking for it. Sometimes we might have a generic element, a specific component that renders inside a modal. When a specific flag is set, the component should get a parent w...

Dec 11, 2022 · 3 min read · h.daily-dev-tips.com  
Read the article

-   [#reactjs](https://hashnode.com/tag/reactjs)
-   [#web-development](https://hashnode.com/tag/web-development)

## Written by

[Chris Bongers](https://hashnode.com/@dailydevtips)

@dailydevtips · Cape Town, SA

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

Looking to get into development? As a full-stack developer I guide you on this journey and give you bite sized tips every single day 👊

I'm a full-stack developer from South Africa 🇿🇦. I love writing about JavaScript, HTML and CSS.

## Responses 2

Markdown supported · ⌘↵ to post

[Md Shakib Ahmed](https://hashnode.com/@mdshakibahmed)

[Dec 11, 2022](https://hashnode.com/posts/conditional-wrapping-in-react/639570a4f31b409c5b358972/comment/63961a5d15750808b269d8ae)

Thank you so much given such a piece of valuable information. it's really helpful for me! I appreciate the author of this article sharing something special. yeah, The main magic, of course, happens in the Conditional Wrapper component and, to be precise, the wrapper argument.✔

I'm super excited to share that I have found Graphicly!

[Graphicly](https://graphicsly.net/) is an all-in-one plugin for graphics management, image cropping, and image optimization. Graphicly lets you easily download and use images from the web,

whether you are on a website or on your WordPress site. With our powerful API, you can create customized libraries of images that integrate seamlessly into your theme’s header.

as a result of reading this post. I'm getting to save your profile in my favorite list. 🥰

[Tamal Das](https://hashnode.com/@tamalCodes)

[Dec 11, 2022](https://hashnode.com/posts/conditional-wrapping-in-react/639570a4f31b409c5b358972/comment/639573d79fa713176ab9d9e8)

Loved the blog Chris !

[Chris Bongers](https://hashnode.com/@dailydevtips)

[Dec 12, 2022](https://hashnode.com/posts/conditional-wrapping-in-react/639570a4f31b409c5b358972/comment/639573d79fa713176ab9d9e8#reply-6396c84d15750808b269ebc0)

Thanks Tamal 🙏
