There are:
5 sides like AB each belonging to 6 triangles
5 sides like FG each belonging to 1 triangle
10 sides like AF each belonging to 3 triangles
10 sides like AG each belonging to 2 triangles
5 sides like AC each belonging to 4 triangles
note
each triangle is mentioned only by its 3 sides above
giving
$6*5+1*5+3*10+2*10+4*5 = 105$ triangle sides
meaning
$105/3=35$ triangles
same reasoning might also help for other, similar, figures, and, perhaps, not only for counting triangles.
same reasoning finds $20$ quadrilaterals in the pentagon
note about counting triangles
One of the tricky parts of most solutions that partition into sets of triangles is that, for each partition block, one can still make human mistakes to not count or to count double. But when partitioning into sides, which, for regular polygons is not that hard and gives less partition blocks, chance for human mistake is gone because: to count triangles in a particular equivalence class of sides, one simply has to go over all remaining points and check if they connect to both side ends. This can be done sequentially, perhaps alphabetically or numerically. But other counting relies on spotting tuples or triples of connected points, which becomes harder to proceed with as human and to not make above mentioned mistakes.