So, download the demo project I zipped up and configure Code::Blocks to use MINGW64 MSys2 GCC and build and run the project.
It worked for me under UCRT64 with package mingw-w64-ucrt-x86_64-sfml installed.
Edit: You do know what an MSYS2 environment is, correct? Example: MINGW64, MINGW32, UCRT64, and etc.
Tim S.