The light-matter interaction associated with a two-dimensional (2D) excitonic transition coupled to a zero-dimensional (0D) photonic cavity is fundamentally different from coupling localized excitations in quantum dots or color centers, which have negligible spatial extent compared to the cavity-confined mode profile. By calculating the radiation-matter coupling of the exciton transition of a surface deposited 2D material and a 0D photonic crystal nanobeam mode, we found that there is an optimal spatial extent of the monolayer material that maximizes such an interaction strength due to the competition between minimizing the excitonic envelope function area and maximizing the total integrated field. This is counter to the intuition from the Dicke model, where the oscillator strength is expected to monotonically grow with the number of oscillators, which correlates to the monolayer area assuming the excitonic wavefunction