Amazon S3 CORS – There is no header & # 39; Access-Control-Allow-Origin & # 39; present in the requested resource

I receive the following error when loading an asset through CloudFront

Access the image at & # 39; https: //example.com/assets/image.png' from the origin
& # 39; https: // localhost: 3000 & # 39; has been blocked by the CORS policy: No
The heading & # 39; Access-Control-Allow-Origin & # 39; is present in the order
resource.

I have configured the S3 CORS policy with the following but does it seem to have no effect?

 
        http: // localhost: 3000
        OBTAIN
        PUT
        SUBMIT
        DELETE
        *
    
    
        https: // localhost: 3000
        OBTAIN
        HEAD
        PUT
        SUBMIT
        DELETE
        *
    

Any idea what else it could be?

Do I need to configure something in Cloudfront?