Yes, it can be used for sentiment analysis.
This library basically means you don't have to write the code for sentiment analysis anymore (just one example).
Just feed it a model:
$ ./fasttext supervised -input train.txt -output model
And then you can predict what the most likely label for a text is: $ ./fasttext predict model.bin test.txt