Search code examples
iosswiftmaterial-components

I cannot import what I need to, to use MaterialContainerScheme


I wanted to switch over to using the beta podspec, and updating my Podfile according to the documentation, and received the error "unable to find a specification for MaterialComponentsbeta`.

Reproduction steps

Steps to reproduce the behavior:

  1. Updated Podfile with pod 'MaterialComponentsBeta', :git => 'https://github.com/material-components/material-components-ios', :branch => 'develop'
  2. Ran pod install.
  3. Received error.

Expected behavior

Install appropriate pod libraries

Actual behavior

Received the following error:

Analyzing dependencies
Pre-downloading: `AlertOnboarding` from `https://github.com/doronkatz/AlertOnboarding.git`, branch `master`
Pre-downloading: `MaterialComponentsBeta` from `https://github.com/material-components/material-components-ios`, branch `develop`
[!] Unable to find a specification for 'MaterialComponentsBeta'.

[!] Unable to load a podspec from `MaterialComponentsSnapshotTests.podspec`, skipping:

Pod::DSLError

[!] Unable to load a podspec from `MaterialComponents.podspec`, skipping:

Pod::DSLError

[!] Unable to load a podspec from `MaterialComponentsBeta.podspec`, skipping:

Pod::DSLError

Platform (please complete the following information)

  • Cocoapod 1.2.0.rc.1
  • Mojave

Solution

  • I think you are using wrong url, you should try following to fix your issue.

    pod 'MaterialComponentsBeta', :git => 'https://github.com/material-components/material-components-ios.git'
    

    See this documentation Material Design Beta Components