Are glyph substitutions in beginnings of paragraphs possible?

I’m designing a script font and would like to make a contextual substitution of a glyphs for its .init variation when it’s not preceded by any glyph. I can sub it whenever it’s after my @Punctuation class (includes spaces etc.) but not when it’s the first character of the text. Any thoughts/tips on how I can make this as I do not want to have my main glyphs to not connect.



ignore [@ANYGLYPH space] @LETTER_NORMAL’;

… but the problem is, wordspace is not always recognized as such, since some text engines use their own wordspacing mechanism, especially web browsers.