react-mdc / react-material-components-web

React wrapper of Google's Material Components Web
https://react-mdc.github.io/
178 stars 15 forks source link

[common] Possible conflict of adapter context #13

Open Hardtack opened 7 years ago

Hardtack commented 7 years ago

We always use adapterfor name of adapter context.

It can occur conflict of adapter when nesting different@react-material components.

<TextField>
  <Input>
  </Input>
  <Checkbox>
    <NativeControl ... />
    ...
    <Input ... /> {/* This Input component will receive checkbox's adapter from the context */}
  </Checkbox>
</TextField>

We may have to add prefix for each context names of components. adapter -> textfieldAdapter