Underline spelling errors


#1

Hi !

I am facing a problem with the spellchek html attribute, but when there is a spelling mistake, the word is not underlined in red, here is how i made :

        <ion-row>
            <ion-col col-sm-6 offset-sm-3>
                <ion-list>
                    <ion-item no-lines>
                        <ion-textarea autocorrect="on" autocomplete="on" spellcheck="on" class="evaluation-comment" [(ngModel)]="comment" placeholder="..."></ion-textarea>
                    </ion-item>
                </ion-list>
            </ion-col>
        </ion-row>

The error is found, i can click on it and a correction is proposed but the word is not underlined in red.

Thanks in advance,

Ben


#2

Howdy,

I think iOS suppresses underlines these days. Check any website in iOS Safari - if you see squiggles anywhere please let me know (and I really mean that).

Android still displays em.

I’ve done a repo with what is currently best practice to the best of my knowledge…


#3

Hi Judgewest2000,

Thank you for your answer,

In fact many modern application have thoses red underlines, apple’s applications but also others like messenger :

I saw in your repo that you put spellcheck=“true”, is it “true” or “on” like autocorrect ? I can’t see it in the ionic input documentation

Best,

Ben


#4

I’ll be honest - I don’t know which should be used. I know those work for me - but I suspect both would.

What you’ve included on that screengrab is not actually a safari thing but a native control - but you could be in luck in either case.

Are you wanting to have it in various text boxes and the like or just for the control as you have shown me in your screen grab (i.e. attached to the keyboard)?


#5

Oh sorry for the confusion, i want to have it in the input directly if it possible, not as in the screen.
In fact i just realised that it’s absolutly not the same thing (native keyboard vs input), so maybe it is not possible…


#6

I’m sure there will be a way.

I’ve had a quick look at this but it requires a licence. It has legs but not feeling it myself.

https://www.npmjs.com/package/cordova-plugin-native-keyboard


#7

In fact testing the application outside the simulator solved the problem, i don’t know how but when i use the application directly on my iPhone, mistakes are underlined in red!

Thanks for the help.

Best,

Ben


#8

Weird- not my finding