No such module as RxRelay / Chapter 3

Hi, I keep getting this error in Chapter 3 Playground.
I have tried the solution given in the Forum already but nothing is wokring

Please help me out here.

I have the same issue. xcode 13.4.1. Macbook pro m1

I have also followed the link steps below but no luck

1 create a new Xcode project with name “RxSwiftPlayground”
2 close the project and open the terminal and run pod init ( I assume you already have coco pod install )
3 open the pod file and pod ‘RxSwift’, ‘5.1.1’ pod ‘RxCocoa’, ‘~> 5.1.0’|
4 save and run pod install|
5 copy the ./bootstrap.sh file into the new project you create|
6 run the ./bootstrap.sh and clear the XCode project it will solve the issue.|

After the steps, will have “Cannot find ‘example’ in scope” error show up. Then I copied “SupportCode.swift” from original project and put into Playground Sources folder. The error has gone. But come with another error, when run the PublishSubject code will show
expression failed to parse:
unknown error

any ides?

I have created new Xcode MacOS project (Command Line tool) and simply installed there new version of RxSwift and RxCocoa. Then I copied to the “main” file example(of: action:) function from original playground project and and started to practice there:)

First, you need to check “Build Active Scheme” in Playground Settings.

Then, I don’t know what caused it, but I just adjusted the import order and it worked.

import Foundation
import RxRelay
import RxSwift
2 Likes

This topic was automatically closed after 166 days. New replies are no longer allowed.