  We investigate the relation between the Hodge theory of a smooth subcanonical
$n$-dimensional projective variety $X$ and the deformation theory of the affine
cone $A_X$ over $X$. We start by identifying $H^{n-1,1}_{\mathrm{prim}}(X)$ as
a distinguished graded component of the module of first order deformations of
$A_X$, and later on we show how to identify the whole primitive cohomology of
$X$ as a distinguished graded component of the Hochschild cohomology module of
the punctured affine cone over $X$. In the particular case of a projective
smooth hypersurface $X$ we recover Griffiths' isomorphism between the primitive
cohomology of $X$ and certain distinguished graded components of the Milnor
algebra of a polynomial defining $X$. The main result of the article can be
effectively exploited to compute Hodge numbers of smooth subcanonical
projective varieties. We provide a few example computation, as well a SINGULAR
code, for Fano and Calabi-Yau threefolds.
