TECHNOLOGY FOCUS - POLYMERS - Preferred Components: The first type of monomer comprises two thiol groups or three thiol groups, and the second type of monomer comprises 1-3 vinyl groups or 1-3 alkynyl groups, such as two vinyl groups or three alkynyl groups. The first type of monomer is a thiol compound of formula (HS-L1-SH) (I), preferably 2-(2-(2-mercapto-ethoxy)-ethoxy)-ethanethiol or (R1aC(L2SH)3), preferably CH3-CH2C(CH2-(O-CH2-CH2)m-O-C(=O)-CH2-CH2-CH2-SH)3. The second type of monomer is substituted hydrocarbyl compounds of formulae (X1-L3-R1b), or (X2-L4-X3). The second type of monomer is (2-(2-(2-vinyloxy-ethoxy)-ethoxy)-ethoxy)-ethene, 1,4-bis-vinyloxymethyl-cyclohexane, 1,3-diethynyl-benzene, N-(3-(2-(2-(3-acryloylamino-propoxy)-ethoxy)-ethoxy)-propyl)-acrylamide, N-(6-acryloylamino-hexyl)-acrylamide, N-(acryloylamino-methyl)-acrylamide or amide of formula (CH2-CH-C(=O)-NH(2-3C alkylene oxide)s-(2-3C alkylene)-NH-C(=O)-CH-CH2). The third type of monomer comprises at least one, at least two or more than two functional group(s) reactive with a thiol group, such as isocyanate groups, cyanate ester groups, thiocyanate groups, isothiocyanate groups, and/or epoxy groups, is hydrocarbyl compound of formula (R1e-L5-R1f). The polymer layer is arranged as a protective layer, as an electrolyte or as a separator. The electroactive layer comprises lithium. The cathode comprises elemental sulfur.L1, L2 = alkylene, heteroalkylene (such as alkylene oxide chain), cycloalkylene, heterocycloalkylene, arylene or heteroarylene (all optionally substituted), where L1 is preferably -(2-3C alkylene oxide)n-(2-3C alkylene)- or -(2-3C alkylene oxide)n-C(O)-(2-3C alkylene)-, and L2 is -(1-3C alkylene)-(2-3C alkylene oxide)m-(1-3C alkylene)- or -(1-3C alkylene)-(2-3C alkylene oxide)m-OC(O)-(1-3C alkylene)-,where the 2-3C alkylene oxide is ethylene oxide or 1,2-propylene oxide;n = 1-100, preferably 1-10;R1a = H, alkyl (both preferred) or -L2SH;m = 1-10;X1 = CR1c=CH2 or -CCH;L3 = optionally substituted alkylene, optionally substituted heteroalkylene, substituted cycloalkylene, optionally substituted heterocycloalkylene, substituted heteroarylene, -(CO)-, -(CO)O-, -(CO)NH-, -C=NH-, -NH-, -C(OH)-, -O- or -S-;R1b = alkyl, heteroalkyl, cycloalkyl, heterocycloalkyl, aryl or heteroaryl (all optionally substituted);R1c = H or alkyl;X2, X3 = -CR1d=CH2 or -CCH;L4 = alkylene, heteroalkylene, cycloalkylene, heterocycloalkylene, arylene, heteroarylene, -(CO)-, -(CO)O-, (CO)NH-, -C=NH-, -NH-, -C(OH)-, -O- or -S-, where L3 or L4 comprises alkylene oxide chain, including alkylene oxide chains comprising a copolymer of alkylene oxide units having different chemical structures, such as an alkylene oxide chain comprising a copolymer of ethylene oxide and 1,2-propylene oxide, preferably L4 is -O-(CH2)m-R6-(CH2)m-O-, -(O)-(2-3C alkylene oxide)r- or -C(=O)-NH-R7-NH-C(=O)-, where 2-3C alkylene oxide is ethylene oxide or 1,2-propylene oxide;R1d = H or alkyl;R6 = alkylene, heteroalkylene, cycloalkylene, heterocycloalkylene, arylene or heteroarylene (all optionally substituted);r = 1-10;R7 = alkylene, heteroalkylene, heterocycloalkylene, cycloalkylene, arylene or heteroarylene (all optionally substituted);s = 1-100;L5 = alkylene, arylene, arylene-alkylene-arylene or alkylene-arylene alkylene (all optionally substituted), preferably phenylene, 4,4'-methylenebis(4,1-phenylene) or 4,4'-(ethane-1,1-diyl)bis(4,1-phenylene); andR1e, R1f = isocyanate, cyanate ester, thiocyanate, isothiocyanate or epoxy, preferably bis(4-isocyanatophenyl)methane, 1,4-diisocyanato-benzene or 4,4'-(ethane-1,1-diyl)bis(cyanatobenzene).