Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

139
Vistas
React native styled components cannot override component's style

I have a weird problem with stlyed components. I have a component Header with a basic style but when a try to use this component and extend the style nothing happens. Can someone tell me what going on?

import styled from 'styled-components/native';
export const Container = styled.SafeAreaView``;

export const Content = styled.View`
  height: 72px;
  padding: 0 24px;
  flex-direction: row;
  align-items: center;
  justify-content: center;
`;

Header component

import React, { PropsWithChildren, FC } from 'react';
import { Container, Content } from './styles';

const Header: FC = ({ children }: PropsWithChildren<unknown>, props) => {
  return (
    <Container {...props}>
      <Content>{children}</Content>
    </Container>
  );
};

export default Header;

import styled from 'styled-components/native';

import Header from '../components/Header/index';

export const Container = styled(Header)`
  background: blue;
  height: 200px;
`;

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda