The parameter is correct in the form of --output type=image,compression=uncompressed,force-compression=true --push
I figured why it was not working. If you use default docker builder, it seems not taking this parameter. If you a builder based on docker-container, it will work as expected.
So you will need to run
docker buildx create --name my-builder --driver docker-container
followed by
docker buildx use my-builder
before issuing the docker buildx build command