devxoul / UITextView-Placeholder

A missing placeholder for UITextView
MIT License
1.48k stars 259 forks source link

Fixes spm support #79

Open AndrewSB opened 4 years ago

MainasuK commented 4 years ago

The current master does not work in Xcode 11.6 with SwiftPM. And also this PR not working.

I believe the header moves to /include will be better. If not change the folder structure. The puclicHeadersPath should be "" empty string. SwiftPM in Xcode 11.6 not accepts "." or nil.

Here is my folk. https://github.com/MainasuK/UITextView-Placeholder/commit/20f513ded04a040cdf5467f0891849b1763ede3b

AndrewSB commented 4 years ago
Screen Shot 2020-08-14 at 8 58 08 AM

I've been using my fork for a few weeks on Xcode 11.6 and the beta 12. Are you sure you're targeting the right branch (AndrewSB/master) in your package manifest?

MainasuK commented 4 years ago

You are right. I'm not change the checkout rules to "branch". After switch to master the package works.

MalcolmnDEV commented 4 years ago

@AndrewSB I am getting this error now on Xcode 12 :

Value of type 'UITextView' has no member 'placeholder'

AndrewSB commented 4 years ago

Could you provide more context around the error please? The full compiler message if you can see it? I haven't downloaded 12 yet.

I'm also more than happy to accept a PR that fixes the issue if you'd like to patch it!

MalcolmnDEV commented 4 years ago

@AndrewSB Thats the only error message that Xcode gives.

Do you think it might be around objective c files inside the package ?

MalcolmnDEV commented 4 years ago

I am trying to access optionTextField.placeholder = ""

This is where the error comes

AndrewSB commented 4 years ago

I can't really tell what might the problem without more context. I can take a look in a couple weeks when I upgrade to Xcode 12

tangbl93 commented 3 years ago

it's works for me

MalcolmnDEV commented 3 years ago

I still get an error on Xcode 12.2.

Value of type 'UITextView' has no member 'placeholder'

MalcolmnDEV commented 3 years ago

Its as if the package does not include placeholder

4brunu commented 3 years ago

This is working for me.

4brunu commented 3 years ago

This PR is working, but Xcode is showing the following warning: /Users/user/Library/Developer/Xcode/DerivedData/Project-beynuwyvodgnkhfdlxfcwaisrsll/SourcePackages/checkouts/UITextView-Placeholder/Sources/include/UITextView+Placeholder.h should be renamed to /Users/user/Library/Developer/Xcode/DerivedData/Project-beynuwyvodgnkhfdlxfcwaisrsll/SourcePackages/checkouts/UITextView-Placeholder/Sources/include/UITextView_Placeholder.h to be used as an umbrella header