I accidentially got two SF313. They are phototransistors, here is a datasheet:
As far as I understand it if I apply +5V to it's collector-emmiter, the current running throw it will be proportional to the ammount of light (that's why it's have "High linearity" feature). Here is a drawing from datasheet:
The dark current and photocurrent as far as I understand is max in the dark and max current with light respectively:
the current running throw it will be proportional to the ammount of light
Well that's not what the graph shows. It is a straight line graph alright but the axis are logarithmic. So the log of the current is proportional to the log of the light.
should I choose a resistor based on max current (30 mA)
Not manuals as such. But look around the web if you want to get more complicated than a single resistor. You can use op amps to linerise the output if you want.